Cambiare porta x11vnc
-
- Prode Principiante
- Messaggi: 21
- Iscrizione: lunedì 20 novembre 2017, 11:49
- Sesso: Maschile
Cambiare porta x11vnc
La porta in questione è la 5900,come server sto usando x11vnc installato. Funziona perfettamente, ma la porta che usa è la 5900 di default. Dopo aver seguito mille guide, l unico comando che funziona senza problemi è
x11vnc -rfbport numero_porta
Ora mi direte che è fatta! Ma il problema è che pur creando uno script con questo codice, da avviare al boot, o inserirlo nel /etc/Rc.local non viene avviato all avvio, cioè la porta resta sempre la 5900.
Se avvio da terminale manuale tutto ok.
Cosa posso provare? Ho seguito tutte le guide che ho trovato, sia in italiano che in inglese.
Grazie mille a tutti in anticipo.
Saluti Antonio ^^
Re: Cambiare porta x11vnc
-
- Prode Principiante
- Messaggi: 21
- Iscrizione: lunedì 20 novembre 2017, 11:49
- Sesso: Maschile
Re: Cambiare porta x11vnc
tu lo hai mai usato? come dovrei fare se voglio dare quel comando ad ogni avvio?
-
- Prode Principiante
- Messaggi: 21
- Iscrizione: lunedì 20 novembre 2017, 11:49
- Sesso: Maschile
Re: Cambiare porta x11vnc
Sembra impossibile. Altra cosa che vorrei tanto capire è perchè manco RealVnc Funziona.
- DoctorStrange
- Imperturbabile Insigne
- Messaggi: 2851
- Iscrizione: mercoledì 14 ottobre 2015, 9:33
- Desktop: Gnome3
- Distribuzione: Ubuntu 22.04 LTS Jammy Jellyfish
- Sesso: Maschile
- Località: Roma, Italia
Re: Cambiare porta x11vnc
il fatto che tu non riesca ad assegnare quella porta magari potrebbe derivare da problemi di altro tipo.
Sei sicuro che non hai qualche altro servizio che contende l'uso di quella stessa porta, oppure che tu non abbia qualche regola di firewall attiva che controlla quella porta?
Hai provato a fare una scansione sia tcp che udp su quella porta sia quando il servizio è attivo, che quando non lo è? Hai provato a pingarla anche dall'esterno della tua rete locale? In pratica, serve che il problema sia caratterizzato in maniera un pò più precisa.
Saluti.
Re: Cambiare porta x11vnc
Codice: Seleziona tutto
crontab -e
Codice: Seleziona tutto
sudo crontab -e
e ci metti dentro una stringa così
Codice: Seleziona tutto
@reboot /path/completa/dello/script >/dev/null 2>&1
-
- Prode Principiante
- Messaggi: 21
- Iscrizione: lunedì 20 novembre 2017, 11:49
- Sesso: Maschile
Re: Cambiare porta x11vnc
Se do il medesimo comando da terminale in modo manuale, la porta viene assegnata senza errori, e ovviamente funziona perfettamente, dato che da remoto riesco a connettermi.harpefalcata [url=https://forum.ubuntu-it.org/viewtopic.php?p=5023320#p5023320][img]https://forum.ubuntu-it.org/images/icons/icona-cita.gif[/img][/url] ha scritto:Rc.local ha priorità nettamente superiore a cron e, oltretutto viene anche eseguito come root.
il fatto che tu non riesca ad assegnare quella porta magari potrebbe derivare da problemi di altro tipo.
Sei sicuro che non hai qualche altro servizio che contende l'uso di quella stessa porta, oppure che tu non abbia qualche regola di firewall attiva che controlla quella porta?
Hai provato a fare una scansione sia tcp che udp su quella porta sia quando il servizio è attivo, che quando non lo è? Hai provato a pingarla anche dall'esterno della tua rete locale? In pratica, serve che il problema sia caratterizzato in maniera un pò più precisa.
Saluti.
L unico problema è che devo dare il comando da terminale in modo manuale.
-
- Prode Principiante
- Messaggi: 21
- Iscrizione: lunedì 20 novembre 2017, 11:49
- Sesso: Maschile
Re: Cambiare porta x11vnc
Fatto come descritto ma nullapachisapiu [url=https://forum.ubuntu-it.org/viewtopic.php?p=5023321#p5023321][img]https://forum.ubuntu-it.org/images/icons/icona-cita.gif[/img][/url] ha scritto:Per eseguire lo script all'avvio : se va eseguito da utente normaleoCodice: Seleziona tutto
crontab -e
se deve essere eseguito da rootCodice: Seleziona tutto
sudo crontab -e
e ci metti dentro una stringa cosìla path completa si intende ad esempio /home/tizio/cartella/script.shCodice: Seleziona tutto
@reboot /path/completa/dello/script >/dev/null 2>&1
Re: Cambiare porta x11vnc
Codice: Seleziona tutto
crontab -l
Codice: Seleziona tutto
ls -al
PS : Va eseguito da root o no ?
-
- Prode Principiante
- Messaggi: 21
- Iscrizione: lunedì 20 novembre 2017, 11:49
- Sesso: Maschile
Re: Cambiare porta x11vnc
Codice: Seleziona tutto
antonio@Desktop ~ $ crontab -l
# Edit this file to introduce tasks to be run by cron.
#
# Each task to run has to be defined through a single line
# indicating with different fields when the task will be run
# and what command to run for the task
#
# To define the time you can provide concrete values for
# minute (m), hour (h), day of month (dom), month (mon),
# and day of week (dow) or use '*' in these fields (for 'any').#
# Notice that tasks will be started based on the cron's system
# daemon's notion of time and timezones.
#
# Output of the crontab jobs (including errors) is sent through
# email to the user the crontab file belongs to (unless redirected).
#
# For example, you can run a backup of all your user accounts
# at 5 a.m every week with:
# 0 5 * * 1 tar -zcf /var/backups/home.tgz /home/
#
# For more information see the manual pages of crontab(5) and cron(8)
#
# m h dom mon dow command
@reboot . /home/antonio/Documenti/Scriptx11vnc.sh >/dev/null 2>&1
Codice: Seleziona tutto
antonio@Desktop ~/Documenti $ ls -al
totale 12
drwxr-xr-x 2 antonio antonio 4096 nov 20 12:45 .
drwxr-xr-x 33 antonio antonio 4096 nov 20 14:10 ..
-rwxrwxrwx 1 root root 32 nov 20 12:45 Scritpx11vnc.sh
Re: Cambiare porta x11vnc
Codice: Seleziona tutto
@reboot /home/antonio/Documenti/Scriptx11vnc.sh >/dev/null 2>&1
Codice: Seleziona tutto
ls -al /home/antonio/Documenti
-
- Prode Principiante
- Messaggi: 21
- Iscrizione: lunedì 20 novembre 2017, 11:49
- Sesso: Maschile
Re: Cambiare porta x11vnc
Tolto il punto e postato la cartella, ho modificato il messaggio precedente.pachisapiu [url=https://forum.ubuntu-it.org/viewtopic.php?p=5023326#p5023326][img]https://forum.ubuntu-it.org/images/icons/icona-cita.gif[/img][/url] ha scritto:c'è un punto di troppo nel crontab , modifica cosìe se non va postaCodice: Seleziona tutto
@reboot /home/antonio/Documenti/Scriptx11vnc.sh >/dev/null 2>&1
Codice: Seleziona tutto
ls -al /home/antonio/Documenti
Cosa intendi come root?
Re: Cambiare porta x11vnc
Codice: Seleziona tutto
sudo chown antinio:antonio /home/antonio/Documenti/Scritpx11vnc.sh
-
- Prode Principiante
- Messaggi: 21
- Iscrizione: lunedì 20 novembre 2017, 11:49
- Sesso: Maschile
Re: Cambiare porta x11vnc
dato il comando. ora riavvio e provo?
Re: Cambiare porta x11vnc
-
- Prode Principiante
- Messaggi: 21
- Iscrizione: lunedì 20 novembre 2017, 11:49
- Sesso: Maschile
Re: Cambiare porta x11vnc
pachisapiu [url=https://forum.ubuntu-it.org/viewtopic.php?p=5023332#p5023332][img]https://forum.ubuntu-it.org/images/icons/icona-cita.gif[/img][/url] ha scritto:certo prova a riavviare e se non va posta di nuovo quei 2 comandi
Codice: Seleziona tutto
antonio@Desktop ~ $ crontab -l
# Edit this file to introduce tasks to be run by cron.
#
# Each task to run has to be defined through a single line
# indicating with different fields when the task will be run
# and what command to run for the task
#
# To define the time you can provide concrete values for
# minute (m), hour (h), day of month (dom), month (mon),
# and day of week (dow) or use '*' in these fields (for 'any').#
# Notice that tasks will be started based on the cron's system
# daemon's notion of time and timezones.
#
# Output of the crontab jobs (including errors) is sent through
# email to the user the crontab file belongs to (unless redirected).
#
# For example, you can run a backup of all your user accounts
# at 5 a.m every week with:
# 0 5 * * 1 tar -zcf /var/backups/home.tgz /home/
#
# For more information see the manual pages of crontab(5) and cron(8)
#
# m h dom mon dow command
@reboot /home/antonio/Documenti/Scriptx11vnc.sh >/dev/null 2>&1
Codice: Seleziona tutto
antonio@Desktop ~/Documenti $ ls -al
totale 12
drwxr-xr-x 2 antonio antonio 4096 nov 20 12:45 .
drwxr-xr-x 33 antonio antonio 4096 nov 20 14:30 ..
-rwxrwxrwx 1 antonio antonio 32 nov 20 12:45 Scritpx11vnc.sh
Nulla da fare ancora
Ma la cosa grave, è che manco RealVnc Funziona! Solo x11vnc, e cambiare la porta sembra impossibile all avvio
Re: Cambiare porta x11vnc
Codice: Seleziona tutto
cd /home/antonio/Documenti
Codice: Seleziona tutto
./Scritpx11vnc.sh
-
- Prode Principiante
- Messaggi: 21
- Iscrizione: lunedì 20 novembre 2017, 11:49
- Sesso: Maschile
Re: Cambiare porta x11vnc
si, perfettamente!pachisapiu [url=https://forum.ubuntu-it.org/viewtopic.php?p=5023337#p5023337][img]https://forum.ubuntu-it.org/images/icons/icona-cita.gif[/img][/url] ha scritto:ma se tu faie poiCodice: Seleziona tutto
cd ~/home/antonio/Documenti
funziona o no ?Codice: Seleziona tutto
./Scritpx11vnc.sh
Re: Cambiare porta x11vnc
Codice: Seleziona tutto
crontab -e
Codice: Seleziona tutto
sudo crontab -e
Codice: Seleziona tutto
@reboot /home/antonio/Documenti/Scriptx11vnc.sh >/dev/null 2>&1
-
- Prode Principiante
- Messaggi: 21
- Iscrizione: lunedì 20 novembre 2017, 11:49
- Sesso: Maschile
Re: Cambiare porta x11vnc
e se volessi usare il programma realvnc? Lui ha grafica e tutto
Chi c’è in linea
Visualizzano questa sezione: 0 utenti iscritti e 11 ospiti