New Fasthosts VPS
New virtual private server for email and seme4.com website
Fasthosts.co.uk “VPS2” (2 cores, 4GB RAM, 120GB NVMe SSD). Debian 12
87.106.35.187
“Cloud Panel” at https://cloud.admin.fasthosts.co.uk/ (username ian.millard@seme4.com)
Initial setup
Login as root with password from control panel.
Hostname
[root@seme4]# hostname seme4.com
edit /etc/hostname to contain seme4.com
IPv6
Allocated new address via web control panel
[root@seme4]# ip address add 2a00:da00:f423:dd00::1 dev ens6
Create users
[root@seme4]# useradd -m -g users -G staff,sudo -s /bin/bash icm
[root@seme4]# useradd -m -g users -G staff,sudo -s /bin/bash hg
[root@seme4]# passwd icm
[root@seme4]# passwd hg
Install sympl
https://sympl.io is an open source fork/extension of the old Bytemark symbiosis hosting utilities.
[root@seme4]# wget -O install-sympl.sh https://gitlab.com/sympl.io/install/-/raw/master/install.sh
[root@seme4]# bash install-sympl.sh
General administration
Note that operations should be undertaken as the sympl user (run sudo su -l sympl)
Do not use root.
Websites, mail, config etc are defined and stored under /srv/seme4.com/ and
should be configured and manipulated primarily using the sympl command line
tool.
See https://wiki.sympl.io/view/Sympl for more info (also possibly https://forum.sympl.io/)
Create website
[sympl@seme4]$ sympl web create subdomain.seme4.com
[sympl@seme4]$ touch /srv/subdomain.seme4.com/config/ssl-only
[sympl@seme4]$ sudo sympl-web-configure
Create database
[sympl@seme4]$ sympl mysql create dbName
Note it actually uses MariaDB
Data transfer from old server
Old: 213.138.114.57
New: 87.106.35.187
On the old host, set a new temporary root password: nXzQK7MwuqHB3PTsCEtYrV
Also edit /etc/ssh/sshd_config and set PermitRootLogin to Yes. Restart with sudo systemctl restart sshd
On the new host stick the following into /home/sympl/.ssh/config
Host 213.138.114.57
User root
HostKeyAlgorithms=+ssh-rsa,ssh-dss
PubkeyAcceptedKeyTypes=+ssh-rsa,ssh-dss
And execute the following commands
[sympl@seme4]$ sudo chown sympl:root /home/sympl/.ssh
[sympl@seme4]$ sudo chmod g+rw /home/sympl/.ssh
[sympl@seme4]$ ssl-keygen
[sympl@seme4]$ ssh-copy-id root@213.138.114.57
We can then rsync effectively from old to new using ssh keys (without password)
A couple of scripts have been written to perform migration
Website
/home/sympl/server-migration/migrate-website.sh transfered the seme4.com wordpress website
Email
/home/sympl/server-migration/migrate-email.sh brings across (all) email
Subversion
Subversion needs to be run under apache, so sticking it on this server.
Fix DNS to point to this server
[sympl@seme4]$ sudo apt install subversion libapache2-mod-svn
[sympl@seme4]$ sympl create web svn.seme4.com
[sympl@seme4]$ sudo sympl-ssl --force svn.seme4.com
[sympl@seme4]$ touch /srv/svn.seme4.com/config/ssl-only
[sympl@seme4]$ sympl create web svn.ianmillard.com
[sympl@seme4]$ sudo sympl-ssl --force svn.ianmillard.com
[sympl@seme4]$ touch /srv/svn.ianmillard.com/config/ssl-only
[sympl@seme4]$ sudo sympl-web-configure
/home/sympl/server-migration/migrate-svn.sh brings across SVN data
After much frustration as to why javascript wasn’t being served…
[sympl@seme4]$ sudo a2disconf javascript-common
[sympl@seme4]$ sudo systemctl reload apache2