How to set up VNC on home network [Manjaro i3]

Hi,

I’d like to install VNC package on my Manjaro i3 running on a laptop (or desktop) on my home router network (standard cable-modem-router from Internet Provider), then VNC into it from another computer.

Does anyone know what the commands are to get the host VNC server to be able to be seen and logged-into from another computer on the intranet?

ex: I just want to do something like this on a client: vnc 192.168.15.1 — then see my host VNC session (x11vnc), or a new session is ok too (tigervnc i think).

Thanks!!

1 Like

Free or payed account wish to install? I have instructions for windscribe free edition.

You want to VNC from Manjaro to Windows on the same LAN? Or Manjaro to Manjaro? Or over the Internet???

:thinking:

That’s commercial VPN software. There are FLOSS alternatives to that.

:innocent:

Free edition if possible!

I want to VNC from another OS on the same LAN into a Manjaro hosting the VNC server.

Ex: iOS into Manjaro , other-linux into Manjaro, etc.

Hello!

Here is a how to for pure tigervnc: TigerVNC - ArchWiki
There are also some guis for the clients.

That’s more of a question for the other OSes instead of Manjaro.

From a Manjaro perspective:

  1. Install by executing:

    pamac install tigervnc
    
  2. Start by executing:

    systemctl start vncserver@:1
    
  3. The server can be found on m.n.o.p:5901 where m.n.o.p is the actual server IP address that you get when executing:

    ip address
    

    If you use multiple X servers add 1 to the port (so Screen 2 will be m.n.o.p:5902, 3 will be m.n.o.p:5903 etc.

That’s it from a Manjaro perspective! :innocent:
If you need more info, read the entire thing here.

:+1:

Thanks! So yeah, that’s actually my precise question. The ‘m.n.o.p’ server address — what (if any) do I need to do in Manjaro (the OS hosting the vncserver) to make the ‘m.n.o.p’ address (and port) show up on the local intranet, assuming I have a standard ISP-provided router&cable-modem (2 in 1)?

And is the ‘m.n.o.p’ the intranet address of the host server, like… the 192.168.x.y number?

Thanks!

See edit to original. And there is nothing you need to do to make it “show up” It’s just there (or not when the server is turned off, obviously)

:wink:

1 Like

Thank you! That helps a lot.

Here are the steps I followed to get it to run as of the latest Manjaro i3, 2020-09-18:

[From Archwiki for Tigervnc:]

  1. Create a password using vncpasswd which will stored the hashed password in ~/.vnc/passwd .

  2. Edit /etc/tigervnc/vncserver.users to define user mappings. Each user defined in this file will have a corresponding port on which its session will run. The number in the file corresponds to a TCP port. By default, :1 is TCP port 5901 (5900+1). If another parallel server is needed, a second instance can then run on the next highest, free port, i.e 5902 (5900+2).

  3. Create ~/.vnc/config and at a minimum, define the type of session desired with a line like session=foo where foo corresponds to which ever DE is to run. One can see which DEs are available on the system by seeing their corresponding .desktop files within /usr/share/xsessions/ .

so for me, session=i3

I used the following:

session=i3
geometry=1920x1080
alwaysshared
  1. Update the /etc/pam.d/tigervnc file

Because it seems that the /etc/pam.d/tigervnc file that comes with it is ‘outdated’; it should have the following contents instead:

/etc/pam.d/tigervnc:


$ cat /etc/pam.d/tigervnc
#%PAM-1.0
session    required     pam_loginuid.so
session    required     pam_namespace.so
session    optional     pam_keyinit.so force revoke
session    required     pam_limits.so
-session   optional     pam_systemd.so
session    required     pam_unix.so
-session   optional     pam_reauthorize.so prepare
  1. Then start by executing: systemctl start vncserver@:1
1 Like

Actually, I am hosting my vncserver on a Manjaro i3 VM (192.168.22.163) running from virt-manager on the actual machine, a Ubuntu 18 (192.168.0.22 for wlp0s20f3, 192.168.100.1 for ‘virbr1’, 192.168.122.1 for ‘virbr0’). There is also a ‘vnet0’ in the ip address list, but it doesn’t have an inet (ip4?) listed, only a inet6 listed.

The VM has a Virtual Network Interfaceof “NAT” type (default settings) (using virt-manager).

Do you know if anything special needs to be done to see the VM from the intranet?

Thanks again

I run bare metal only, so no VM knowledge in my :brain:

:sob:

1 Like

Got it! Thanks for updating me ! :smiley:

1 Like

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.