On Tue, 9 May 2023 07:36:12 -0400, "Bo Berglund" <bo.bergl...@gmail.com> wrote:
>I am running a backup subversion server on an Ubuntu 20.04.6 LTS SERVER. >The subversion version is: 1.13.0 (r1867053) > >The subversion data are located in /var/lib/svn and it has caused the root >file system to be all used up such that much don't work anymore like apt... > >The root partition is 30 GB and the svn data is about 18 GB of thatÂ… > >$ du -c -h -s /var/lib/svn/ >18G /var/lib/svn/ >18G total > >I need to fix this urgently and therefore I want to know how to go about it. > >Currently there is a spare partition on the disk which is currently mounted in >the /home tree: >$ df -h >... >/dev/nvme0n1p7 79G 56M 75G 1% /home/bosse/data >... > >In /etc/fstab it is mounted like this: > >#So far unused data partition on main drive (will not be visible across NFS >share...): >UUID=fb4a08b7-378e-42eb-9b7a-2c7b4f85cd06 /home/bosse/data ext4 nodev,nosuid >0 2 > > >Can I use this data drive by this sequence of commands: >1) Stop the subversion service (how?) > >2) Move /var/lib/svn to the root of the so far unused data drive > sudo mv /var/lib/svn /home/bosse/data > thus freeing up the 18GB of data used by svn > >3) Edit the /etc/fstab entry such that it will mount the copied dir into >/var/lib as svn > > UUID=fb4a08b7-378e-42eb-9b7a-2c7b4f85cd06 /var/lib/svn ext4 nodev,nosuid 0 > 2 > (Do I need to create the /var/lib/svn dir manually or will the mount make > it work?) > >4) Restart the subversion service > I fixed it by using the steps above: ------------------------------------ 1) sudo systemctl stop apache2 2) sudo mv /var/lib/svn/* /home/user/data 3) Fstab: UUID=fb4a08b7-378e-42eb-9b7a-2c7b4f85cd06 /var/lib/svn ext4 nodev,nosuid 0 2 4) sudo systemctl start apache2 Now the svn dir and below are on the other partition and the system behaves normally with an 18GB margin for / being full. -- Bo Berglund Developer in Sweden