SimulPiscator / AirSane

Publish SANE scanners to MacOS, Android, and Windows via Apple AirScan.
GNU General Public License v3.0
243 stars 26 forks source link

Not work after Reboot #84

Closed chodorenko closed 2 years ago

chodorenko commented 2 years ago

Hello, After reboot computer AirSaned start which systemd and work not correct. Not show Icons and not find scanner by network. Please view screen Screen_1 After reboot service, or connect disconnect scanner, or press Reset link on local site service reload and work correct Screen_2

I reboot computer which --debug=true flag and view connect not all network interfaces on first start, May be need add requirements on Systemd init or check new interfaces UP ?

chodorenko:/home/chodorenko # journalctl -u airsaned -- Logs begin at Wed 2022-02-02 21:40:09 +03, end at Thu 2022-02-03 00:40:08 +03. -- Feb 02 21:40:10 chodorenko systemd[1]: Started AirSane Imaging Service. Feb 02 21:40:10 chodorenko airsaned[1207]: git commit: N/A (branch N/A, rev N/A+) Feb 02 21:40:10 chodorenko airsaned[1207]: build date: 2022-02-02T12:00:00Z Feb 02 21:40:10 chodorenko airsaned[1207]: reading device options from '/etc/airsane/options.conf' Feb 02 21:40:10 chodorenko airsaned[1207]: enumerating local devices... Feb 02 21:40:10 chodorenko airsaned[1207]: sane_init(nullptr, nullptr) Feb 02 21:40:10 chodorenko airsaned[1207]: sane_get_devices() ... Feb 02 21:40:10 chodorenko airsaned[1207]: ... sane_get_devices() -> SANE_Status Success Feb 02 21:40:10 chodorenko airsaned[1207]: sane_exit() Feb 02 21:40:10 chodorenko airsaned[1207]: found: pixma:04A927D1_0173KG41024E (CANON Canon i-SENSYS MF230 Series) Feb 02 21:40:10 chodorenko airsaned[1207]: stable unique name: pixma:CANON Canon i-SENSYS MF230 Series:1 Feb 02 21:40:10 chodorenko airsaned[1207]: uuid: cd53ef86-371e-5ecd-9ec7-a0ffc33438cf Feb 02 21:40:10 chodorenko airsaned[1207]: sane_init(nullptr, nullptr) Feb 02 21:40:11 chodorenko airsaned[1207]: sane_open(pixma:04A927D1_0173KG41024E) -> 0x7ff7c401e2b0 Feb 02 21:40:11 chodorenko airsaned[1207]: [source] := "Flatbed" -> reload options Feb 02 21:40:11 chodorenko airsaned[1207]: [source] := "Automatic Document Feeder" -> reload options Feb 02 21:40:11 chodorenko airsaned[1207]: sane_close(0x7ff7c401e2b0) Feb 02 21:40:11 chodorenko airsaned[1207]: sane_exit() Feb 02 21:40:11 chodorenko airsaned[1207]: published as 'CANON Canon i-SENSYS MF230 Series' Feb 02 21:40:11 chodorenko airsaned[1207]: listening on 127.0.0.1:8090 Feb 02 21:40:11 chodorenko airsaned[1207]: listening on [::1]:8090 Feb 02 21:40:25 chodorenko airsaned[1207]: Warning: Error 404 when requesting "/favicon.ico" Feb 02 21:41:43 chodorenko airsaned[1207]: Warning: Error 404 when requesting "" Feb 02 21:41:52 chodorenko airsaned[1207]: received SIGHUP, reloading Feb 02 21:41:52 chodorenko airsaned[1207]: reading device options from '/etc/airsane/options.conf' Feb 02 21:41:52 chodorenko airsaned[1207]: enumerating local devices... Feb 02 21:41:52 chodorenko airsaned[1207]: sane_init(nullptr, nullptr) Feb 02 21:41:52 chodorenko airsaned[1207]: sane_get_devices() ... Feb 02 21:41:53 chodorenko airsaned[1207]: ... sane_get_devices() -> SANE_Status Success Feb 02 21:41:53 chodorenko airsaned[1207]: sane_exit() Feb 02 21:41:53 chodorenko airsaned[1207]: found: pixma:04A927D1_0173KG41024E (CANON Canon i-SENSYS MF230 Series) Feb 02 21:41:53 chodorenko airsaned[1207]: stable unique name: pixma:CANON Canon i-SENSYS MF230 Series:1 Feb 02 21:41:53 chodorenko airsaned[1207]: uuid: cd53ef86-371e-5ecd-9ec7-a0ffc33438cf Feb 02 21:41:53 chodorenko airsaned[1207]: sane_init(nullptr, nullptr) Feb 02 21:41:54 chodorenko airsaned[1207]: sane_open(pixma:04A927D1_0173KG41024E) -> 0x7ff7c402a0d0 Feb 02 21:41:54 chodorenko airsaned[1207]: [source] := "Flatbed" -> reload options Feb 02 21:41:54 chodorenko airsaned[1207]: [source] := "Automatic Document Feeder" -> reload options Feb 02 21:41:54 chodorenko airsaned[1207]: sane_close(0x7ff7c402a0d0) Feb 02 21:41:54 chodorenko airsaned[1207]: sane_exit() Feb 02 21:41:54 chodorenko airsaned[1207]: published as 'CANON Canon i-SENSYS MF230 Series' Feb 02 21:41:54 chodorenko airsaned[1207]: listening on 127.0.0.1:8090 Feb 02 21:41:54 chodorenko airsaned[1207]: listening on 192.168.1.11:8090 Feb 02 21:41:54 chodorenko airsaned[1207]: listening on [::1]:8090 Feb 02 21:41:54 chodorenko airsaned[1207]: listening on [fe80::da3b:bfff:fe22:317f]:8090

SimulPiscator commented 2 years ago

Hi, the log shows that airsane is listening on all interfaces. If you point your browser to 192.168.1.11:8090, do you get the airsane page?

chodorenko commented 2 years ago

No its no true , first start on Feb 02 21:40:11 chodorenko airsaned[1207]: listening on 127.0.0.1:8090 Feb 02 21:40:11 chodorenko airsaned[1207]: listening on [::1]:8090

After reload bind to all interfaces Feb 02 21:41:54 chodorenko airsaned[1207]: listening on 127.0.0.1:8090 Feb 02 21:41:54 chodorenko airsaned[1207]: listening on 192.168.1.11:8090 Feb 02 21:41:54 chodorenko airsaned[1207]: listening on [::1]:8090 Feb 02 21:41:54 chodorenko airsaned[1207]: listening on [fe80::da3b:bfff:fe22:317f]:8090

And i try start which option INTERFACE=lo and i get at the same problems on web interface as illustrated on Screen_1

SimulPiscator commented 2 years ago

The airsane systemd configuration file tries to wait for all interfaces to be up, so I don't understand why you cannot connect to 192.168.1.11:8090.

Still, you might try to add ExecStartPre=/bin/sleep 15 into the systemd service file. This has helped other users with similar problems.

chodorenko commented 2 years ago

yes its true , its fix problem, May be good idea add its to default systemd unit in you git.