Friday, June 30, 2017

using usb or cd to rescue ruined ubuntu

sudo fdisk -l

find out the disk you want to mount

then

sudo mount /dev/YOUR-DISK /mnt

sudo chroot /mnt

then you have the permission to operate on that disk


text mode

ubuntu@ubuntu:/$ sudo systemctl get-default
graphical.target
ubuntu@ubuntu:/$ sudo systemctl set-default graphical.target
Created symlink from /etc/systemd/system/default.target to /lib/systemd/system/graphical.target.
ubuntu@ubuntu:/$ sudo systemctl get-default
graphical.target


No comments: