Install for
Download ConfigurationSetup steps
Open the steps for your operating system.
Fedora KDE and Kubuntu
On Kubuntu 24.04, first open the Konsole app and run
sudo apt install network-manager-openvpn.
- Open System Settings and go to Wi-Fi & Networking, which Kubuntu 24.04 calls Connections. Click + and choose Import VPN connection.
-
Select
linux.ovpn. It is usually in your Downloads folder. - In the VPN tab, enter your IIIT email address as the user name and your password as the password. Click the icon at the end of the password field and choose Store password for this user only (encrypted).
- In the IPv4 tab, click Routes and turn on Use only for resources on this connection. Do not skip this step, because without it other websites stop loading. Click OK, then Apply.
- Click the network icon in the bottom right corner and connect to the VPN.
Ubuntu, Fedora Workstation and Debian
On Debian, first open the Terminal app, run
sudo apt install systemd-resolved network-manager-openvpn-gnome,
and restart the computer.
- Open Settings and go to Network. Click + next to VPN and choose Import from file.
-
Select
linux.ovpn. It is usually in your Downloads folder. - In the Identity tab, enter your IIIT email address as the user name and your password as the password. Click the icon at the end of the password field and choose Store the password only for this user.
- In the IPv4 tab, turn on Use this connection only for resources on its network. Do not skip this step, because without it other websites stop loading. Click Add.
- Click the top right corner of the screen and turn on the VPN.
Linux Mint and LMDE
On LMDE, first open the Terminal app, run
sudo apt install systemd-resolved, and restart the computer.
- Open System Settings and go to Network. Click + and choose Import from file.
-
Select
linux.ovpn. It is usually in your Downloads folder. - In the Identity tab, enter your IIIT email address as the user name and your password as the password. Click the icon at the end of the password field and choose Store the password only for this user.
- In the IPv4 tab, turn on Use this connection only for resources on its network. Do not skip this step, because without it other websites stop loading. Click Add.
- Click the network icon in the bottom right corner and connect to the VPN.
Other distributions
Use these steps on Arch and other distributions if your desktop environment is GNOME, KDE Plasma or Cinnamon. The desktop environment is the part of the system that draws the windows, the panel and the settings app.
-
Install the OpenVPN plugin for NetworkManager. On Arch, the package is
networkmanager-openvpn. -
Make sure systemd-resolved is running. The VPN file uses it to send only
iiit.ac.inlookups to the campus DNS server. - Follow the steps above for your desktop environment. Use the Ubuntu steps for GNOME, the Fedora KDE steps for KDE Plasma, or the Linux Mint steps for Cinnamon.
Command line
Use these steps on Arch, Gentoo, Alpine and other distributions without a desktop environment, or if you prefer the command line.
NetworkManager
nmtui cannot import VPN files, so use nmcli. Put your own email address in place of the example address.
nmcli connection import type openvpn file linux.ovpn
nmcli connection modify linux \
+vpn.data username=name@students.iiit.ac.in \
ipv4.never-default yes
nmcli connection up linux --ask
The last command asks for your password each time. To keep the password
in a file instead, create a file that only you can read, and write
vpn.secrets.password: followed by your password on one line:
install -m 600 /dev/null ~/.config/iiit.pass
nano ~/.config/iiit.pass
nmcli connection up linux passwd-file ~/.config/iiit.pass
OpenVPN
Install OpenVPN 2.5 or later and run
sudo openvpn --config linux.ovpn. The VPN is
connected when the log shows
Initialization Sequence Completed. The log may show errors
about mssfix, tun-mtu or
dns-updown, and these do not stop the connection. OpenVPN
asks for your email address and password each time. The boot steps below
keep them in a file that only root can read.
Connect at boot with systemd
Copy the file, make it read the password from a file, and create that file with your email address on the first line and your password on the second:
sudo cp linux.ovpn /etc/openvpn/client/iiit.conf
sudo sed -i 's/^auth-user-pass$/auth-user-pass iiit.pass/' \
/etc/openvpn/client/iiit.conf
sudo install -m 600 /dev/null /etc/openvpn/client/iiit.pass
sudoedit /etc/openvpn/client/iiit.pass
sudo systemctl enable --now openvpn-client@iiit
Connect at boot with OpenRC
As root, copy the file, make it read the password from a file, and create
that file with your email address on the first line and your password on
the second. The dns-updown force line is removed because the
OpenRC service sets the DNS itself.
cp linux.ovpn /etc/openvpn/iiit.conf
sed -i -e 's|^auth-user-pass$|auth-user-pass /etc/openvpn/iiit.pass|' \
-e '/^dns-updown force$/d' /etc/openvpn/iiit.conf
install -m 600 /dev/null /etc/openvpn/iiit.pass
vi /etc/openvpn/iiit.pass
ln -s openvpn /etc/init.d/openvpn.iiit
rc-update add openvpn.iiit default
rc-service openvpn.iiit start
Without systemd-resolved
Without systemd-resolved, the log shows
systemd-resolved is not in use and OpenVPN 2.7 or later is
needed. While the VPN is on, every DNS lookup goes to the campus DNS
server, so some outside websites may not load. On Alpine, use the OpenRC
service, because openvpn run by hand does not set the DNS
there.
To check that campus names resolve, run
getent hosts mess.iiit.ac.in. The address should start with
10..
Check the connection
Turn on the VPN and open these sites. All three should load.
- mess.iiit.ac.in, which works only through the VPN
- iiit.ac.in
- duckduckgo.com
Troubleshooting
- If other websites stop loading, make sure the IPv4 option from your setup steps is on.
- If you changed your IIIT password, open the VPN connection in your network settings and enter the new password.
- The VPN does not connect on IIIT WiFi or LAN. Connect through another network, such as your mobile hotspot.
- If your password is rejected, check that the user name is your full IIIT email address.
- If the VPN worked before and has stopped, download the configuration again. Delete the old VPN connection and import the new file.