What was the exact login command used? Did it succeed? (Allowing remote login directly to root is generally discouraged, but some people allow it anyway from their local network.) Are you sure you are logged in to the right machine (look at output from "uname -a")?
You can't
reduce the size of an ext3 filesystem while it is mounted, so you'll have to boot from separate media (SystemRescueCD is fine) and work on the unmounted filesystem. Details about the device mapper aren't really involved in this. There are several steps to be followed, and things need to be done in the right order. Assuming you want to transfer 5GB from /home to the root directory:
Code:
e2fsck -f /dev/mapper/vg1-home # resize2fs will insist on this being done first
resize2fs /dev/mapper/vg1-home 760G # reduce the size by more than enough. I've reduced by 10GB.
lvreduce -L -5G /dev/mapper/vg1-home # shrink the LV by 5GB -- Note: upper-case "L"
e2fsck -f /dev/mapper/vg1-home # make sure the filesystem is still OK
If that last
e2fsck fails, STOP. You did not shrink the filesystem enough, and now
lvreduce has chopped off its tail. You will need to run
vgcfgrestore with the appropriate file in /etc/lvm/archive to safely restore the volume group back to its former condition. Simply running
lvextend is
not safe since there is no guarantee that the LV will get back the same disk blocks it was using before.
Code:
resize2fs /dev/mapper/vg1-home # expand home filesystem to fill the current size of the LV
e2fsck -f /dev/mapper/vg1-root # again, resize2fs will insist
lvextend -l +100%FREE /dev/mapper/vg1-root # enlarge the root LV as much as possible -- Note: lower-case "l"
resize2fs /dev/mapper/vg1-root # expand root filesystem to fill its LV
See how simple LVM makes all this? No???
Note: It's important to reduce the filesystem initially by
more than enough since there may be roundoff errors, and you don't want to risk leaving the filesystem just a little too large for its new, smaller conatiner.