View previous topic :: View next topic |
Author |
Message |
zar Marco Guru
Joined: 09 Sep 2016 Posts: 445 Location: Colle Umberto ( TV )
|
Posted: Fri Oct 06, 2017 9:37 am Post subject: |
|
|
Il problema è che hanno lo stesso UUID, ero andato per modificarlo ma è lo stesso
Code: | ┌─[root@hptoo] - [/home/martoo] - [2017-10-06 11:36:30]
└─[0] <> blkid
/dev/sdb2: UUID="254cbe70-ff7d-47e4-9a6a-e6a771ba66eb" TYPE="ext4" PARTUUID="565613c9-02"
/dev/sda1: LABEL="SYSTEM" UUID="D224-521F" TYPE="vfat" PARTLABEL="EFI system partition" PARTUUID="06a19107-706c-4700-8087-1d6a2a5334ff"
/dev/sda6: UUID="1d596c35-2e8d-4796-9a19-83770e497450" TYPE="swap" PARTUUID="69cc3fed-50ec-4be0-a39e-fc7971ce0ef3"
/dev/sda7: UUID="5849d6b6-3410-41d1-a1ec-a3cb9f78a9e8" TYPE="ext4" PARTUUID="aa40d595-9255-4085-b481-7071fe3cb20e"
/dev/sdb1: UUID="254cbe70-ff7d-47e4-9a6a-e6a771ba66eb" TYPE="ext4" PARTUUID="565613c9-01"
|
cambia il PARTUUID
Questo è il fstab vecchio, cioè quello in funzione
Code: | ┌─[root@hptoo] - [/home/martoo] - [2017-10-06 11:36:33]
└─[0] <> cat /etc/fstab
# /etc/fstab: static file system information.
#
# noatime turns off atimes for increased performance (atimes normally aren't
# needed); notail increases performance of ReiserFS (at the expense of storage
# efficiency). It's safe to drop the noatime options if you want and to
# switch between notail / tail freely.
#
# The root filesystem should have a pass number of either 0 or 1.
# All other filesystems should have a pass number of 0 or greater than 1.
#
# See the manpage fstab(5) for more information.
#
# <fs> <mountpoint> <type> <opts> <dump/pass>
# NOTE: If your BOOT partition is ReiserFS, add the notail option to opts.
UUID=D224-521F /boot/efi vfat noauto,noatime 1 2
UUID=254cbe70-ff7d-47e4-9a6a-e6a771ba66eb / ext4 noatime 0 1
UUID=5849d6b6-3410-41d1-a1ec-a3cb9f78a9e8 /home ext4 noatime 0 1
UUID=c236450a-9460-4315-989f-bfcb0d4e63ee none swap sw 0 0
/dev/cdrom /mnt/cdrom auto noauto,ro 0 0
/dev/fd0 /mnt/floppy auto noauto 0 0
tmpfs /var/tmp/portage tmpfs size=8G,uid=portage,gid=portage,mode=775,noatime 0 0
|
Questo è di quello clonato
Code: | (chroot) hptoo / # cat /etc/fstab
# /etc/fstab: static file system information.
#
# noatime turns off atimes for increased performance (atimes normally aren't
# needed); notail increases performance of ReiserFS (at the expense of storage
# efficiency). It's safe to drop the noatime options if you want and to
# switch between notail / tail freely.
#
# The root filesystem should have a pass number of either 0 or 1.
# All other filesystems should have a pass number of 0 or greater than 1.
#
# See the manpage fstab(5) for more information.
#
# <fs> <mountpoint> <type> <opts> <dump/pass>
# NOTE: If your BOOT partition is ReiserFS, add the notail option to opts.
UUID=D224-521F /boot/efi vfat noauto,noatime 1 2
UUID=254cbe70-ff7d-47e4-9a6a-e6a771ba66eb / ext4 noatime 0 1
UUID=5849d6b6-3410-41d1-a1ec-a3cb9f78a9e8 /home ext4 noatime 0 1
UUID=c236450a-9460-4315-989f-bfcb0d4e63ee none swap sw 0 0
/dev/cdrom /mnt/cdrom auto noauto,ro 0 0
/dev/fd0 /mnt/floppy auto noauto 0 0
tmpfs /var/tmp/portage tmpfs size=8G,uid=portage,gid=portage,mode=775,noatime 0 0
|
|
|
Back to top |
|
|
Maxxx Guru
Joined: 12 Jan 2016 Posts: 595 Location: Italia
|
Posted: Fri Oct 06, 2017 9:55 am Post subject: |
|
|
Non vorrei che Grub avvii correttamente /dev/sdb1 come /boot (che potrebbe essere "hd1,msdos1" su grub.cfg), ma tramite la riga
Code: |
linux /boot/kernel-genkernel-x86_64-4.12.12-gentoo root=UUID=254cbe70-ff7d-47e4-9a6a-e6a771ba66eb ro |
carica il sistema operativo presente su sdb2, visto l'UUID. |
|
Back to top |
|
|
zar Marco Guru
Joined: 09 Sep 2016 Posts: 445 Location: Colle Umberto ( TV )
|
Posted: Fri Oct 06, 2017 10:00 am Post subject: |
|
|
Ora ho provato a reinstallare grub in chroot, provo a riavviare e se parte sempre da sdb2 vorrei provare a cancellare la partizione |
|
Back to top |
|
|
Maxxx Guru
Joined: 12 Jan 2016 Posts: 595 Location: Italia
|
Posted: Fri Oct 06, 2017 10:14 am Post subject: |
|
|
Prima di cancellare la partizione sdb2 io la salverei anche su /home (/sda7)... un backup su un altro disco fisico è più sicuro.
Comunque non so se così risolvi lo stesso, perchè se come suppongo ti carica sdb2, trovandola vuota non avvia nessun sistema operativo.
Non lo so, ma se fosse una cosa fattibile io proverei ad "accorpare" sdb2 (una volta salvata e cancellata) su sdb1 di modo che diventi una partizione unica. |
|
Back to top |
|
|
zar Marco Guru
Joined: 09 Sep 2016 Posts: 445 Location: Colle Umberto ( TV )
|
Posted: Fri Oct 06, 2017 10:23 am Post subject: |
|
|
Se no avevo anche pensato di cambiare fstab rimettendo il numero della partizione al posto degli UUID, e dopo rilanciare l'installazione di grub. Vedo come fare, magari la tua proposta è la più pratica |
|
Back to top |
|
|
Maxxx Guru
Joined: 12 Jan 2016 Posts: 595 Location: Italia
|
Posted: Fri Oct 06, 2017 10:26 am Post subject: |
|
|
no, hai ragione tu... più pratica è cambiare fstab rimettendo il numero della partizione.
Prima prova così, tanto per vedere se funziona. Successivamente, avendo una sdb2 vuota, vedrai cosa farci. |
|
Back to top |
|
|
zar Marco Guru
Joined: 09 Sep 2016 Posts: 445 Location: Colle Umberto ( TV )
|
Posted: Fri Oct 06, 2017 10:29 am Post subject: |
|
|
Poi chiaramente riaccorperò lo spazio ad sdb1, e magari rimetto gli UUID. Poi vedrò se tenere 250 gb di Root o magari provare ad installare qualcos'altro
Edit:
Ho messo la dicitura classica al posto degli UUID in fstab, ma continua a partire la vecchia gentoo, ma credo di avere un altro problema.
Ho provato a reinstallare grub, tramite chroot ma già dando emerge --sync mi da error3 e se provo a reinstallare un pacchetto già installato (grub2) mi va in errore |
|
Back to top |
|
|
Maxxx Guru
Joined: 12 Jan 2016 Posts: 595 Location: Italia
|
Posted: Fri Oct 06, 2017 12:25 pm Post subject: |
|
|
Una cosa mi sfugge, come fai a capire che avvia la vecchia gentoo invece della nuova se la nuova é un clone esatto della vecchia? Ti accorgi perché sdb1 é smontato? |
|
Back to top |
|
|
zar Marco Guru
Joined: 09 Sep 2016 Posts: 445 Location: Colle Umberto ( TV )
|
Posted: Fri Oct 06, 2017 1:02 pm Post subject: |
|
|
perché questo è l'output di mount
Code: | ┌─[root@hptoo] - [/home/martoo] - [2017-10-06 02:58:42]
└─[0] <> mount
proc on /proc type proc (rw,nosuid,nodev,noexec,relatime)
none on /run type tmpfs (rw,nosuid,nodev,relatime,mode=755)
udev on /dev type devtmpfs (rw,nosuid,relatime,size=10240k,nr_inodes=1013885,mode=755)
devpts on /dev/pts type devpts (rw,relatime,gid=5,mode=620,ptmxmode=000)
tmpfs on /dev/shm type tmpfs (rw,nosuid,nodev)
sysfs on /sys type sysfs (rw,nosuid,nodev,noexec,relatime)
/dev/sdb2 on / type ext4 (rw,noatime,data=ordered)
mqueue on /dev/mqueue type mqueue (rw,nosuid,nodev,noexec,relatime)
debugfs on /sys/kernel/debug type debugfs (rw,nosuid,nodev,noexec,relatime)
configfs on /sys/kernel/config type configfs (rw,nosuid,nodev,noexec,relatime)
fusectl on /sys/fs/fuse/connections type fusectl (rw,nosuid,nodev,noexec,relatime)
efivarfs on /sys/firmware/efi/efivars type efivarfs (ro,relatime)
cgroup_root on /sys/fs/cgroup type tmpfs (rw,nosuid,nodev,noexec,relatime,size=10240k,mode=755)
openrc on /sys/fs/cgroup/openrc type cgroup (rw,nosuid,nodev,noexec,relatime,release_agent=/lib64/rc/sh/cgroup-release-agent.sh,name=openrc)
cpuset on /sys/fs/cgroup/cpuset type cgroup (rw,nosuid,nodev,noexec,relatime,cpuset)
cpuacct on /sys/fs/cgroup/cpuacct type cgroup (rw,nosuid,nodev,noexec,relatime,cpuacct)
/dev/sda7 on /home type ext4 (rw,noatime,stripe=32741,data=ordered)
tmpfs on /var/tmp/portage type tmpfs (rw,noatime,size=8388608k,mode=775,uid=250,gid=250)
binfmt_misc on /proc/sys/fs/binfmt_misc type binfmt_misc (rw,nosuid,nodev,noexec,relatime)
none on /run/user/1000 type tmpfs (rw,relatime,mode=700,uid=1000)
/dev/sda1 on /mnt/gentoo/boot type vfat (rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,errors=remount-ro)
/dev/sdb1 on /mnt/gentoo type ext4 (rw,relatime,stripe=32732,data=ordered)
udev on /mnt/gentoo/dev type devtmpfs (rw,nosuid,relatime,size=10240k,nr_inodes=1013885,mode=755)
devpts on /mnt/gentoo/dev/pts type devpts (rw,relatime,gid=5,mode=620,ptmxmode=000)
tmpfs on /mnt/gentoo/dev/shm type tmpfs (rw,nosuid,nodev)
mqueue on /mnt/gentoo/dev/mqueue type mqueue (rw,nosuid,nodev,noexec,relatime)
/proc on /mnt/gentoo/proc type proc (rw,relatime)
sysfs on /mnt/gentoo/sys type sysfs (rw,nosuid,nodev,noexec,relatime)
debugfs on /mnt/gentoo/sys/kernel/debug type debugfs (rw,nosuid,nodev,noexec,relatime)
configfs on /mnt/gentoo/sys/kernel/config type configfs (rw,nosuid,nodev,noexec,relatime)
fusectl on /mnt/gentoo/sys/fs/fuse/connections type fusectl (rw,nosuid,nodev,noexec,relatime)
efivarfs on /mnt/gentoo/sys/firmware/efi/efivars type efivarfs (ro,relatime)
cgroup_root on /mnt/gentoo/sys/fs/cgroup type tmpfs (rw,nosuid,nodev,noexec,relatime,size=10240k,mode=755)
openrc on /mnt/gentoo/sys/fs/cgroup/openrc type cgroup (rw,nosuid,nodev,noexec,relatime,release_agent=/lib64/rc/sh/cgroup-release-agent.sh,name=openrc)
cpuset on /mnt/gentoo/sys/fs/cgroup/cpuset type cgroup (rw,nosuid,nodev,noexec,relatime,cpuset)
cpuacct on /mnt/gentoo/sys/fs/cgroup/cpuacct type cgroup (rw,nosuid,nodev,noexec,relatime,cpuacct)
/dev/sdb2 on /mnt/gentoo/tmp type ext4 (rw,noatime,data=ordered)
/dev/sda1 on /mnt/gentoo/boot/efi type vfat (rw,noatime,fmask=0022,dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,errors=remount-ro)
|
ora sono in chroot su sdb1 ma come vedi non lo segna.
Se provo a dare mount da terminale in chroot mi da questo
Code: | root on hptoo ven ott 06 14:59:12
[dir.= /] > mount
/dev/sdb1 on / type ext4 (rw,relatime,stripe=32732,data=ordered)
udev on /dev type devtmpfs (rw,nosuid,relatime,size=10240k,nr_inodes=1013885,mode=755)
devpts on /dev/pts type devpts (rw,relatime,gid=5,mode=620,ptmxmode=000)
tmpfs on /dev/shm type tmpfs (rw,nosuid,nodev)
mqueue on /dev/mqueue type mqueue (rw,nosuid,nodev,noexec,relatime)
/proc on /proc type proc (rw,relatime)
sysfs on /sys type sysfs (rw,nosuid,nodev,noexec,relatime)
debugfs on /sys/kernel/debug type debugfs (rw,nosuid,nodev,noexec,relatime)
configfs on /sys/kernel/config type configfs (rw,nosuid,nodev,noexec,relatime)
fusectl on /sys/fs/fuse/connections type fusectl (rw,nosuid,nodev,noexec,relatime)
efivarfs on /sys/firmware/efi/efivars type efivarfs (ro,relatime)
cgroup_root on /sys/fs/cgroup type tmpfs (rw,nosuid,nodev,noexec,relatime,size=10240k,mode=755)
openrc on /sys/fs/cgroup/openrc type cgroup (rw,nosuid,nodev,noexec,relatime,release_agent=/lib64/rc/sh/cgroup-release-agent.sh,name=openrc)
cpuset on /sys/fs/cgroup/cpuset type cgroup (rw,nosuid,nodev,noexec,relatime,cpuset)
cpuacct on /sys/fs/cgroup/cpuacct type cgroup (rw,nosuid,nodev,noexec,relatime,cpuacct)
/dev/sdb2 on /tmp type ext4 (rw,noatime,data=ordered)
/dev/sda1 on /boot/efi type vfat (rw,noatime,fmask=0022,dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,errors=remount-ro) |
|
|
Back to top |
|
|
Maxxx Guru
Joined: 12 Jan 2016 Posts: 595 Location: Italia
|
Posted: Fri Oct 06, 2017 1:37 pm Post subject: |
|
|
Quindi se all'avvio non monta sdb1 vuol dire che grub avvia sdb2...
Io sul mio fstab, come opzione sulla partizione di /boot ho "defaults", mentre tu hai "noauto,noatime"... l'opzione noauto significa che il device non deve essere montato automaticamente, ma può essere montato con un comando esplicito... l'opzione defaults, invece, include "auto", vedi qua:
https://it.wikipedia.org/wiki/Fstab |
|
Back to top |
|
|
Maxxx Guru
Joined: 12 Jan 2016 Posts: 595 Location: Italia
|
Posted: Fri Oct 06, 2017 1:54 pm Post subject: |
|
|
Scusa, mi faresti una prova?
Dimmi l'output di
Code: | ls -al /dev/desk/by-uuid |
da chroot su sdb1 |
|
Back to top |
|
|
zar Marco Guru
Joined: 09 Sep 2016 Posts: 445 Location: Colle Umberto ( TV )
|
Posted: Fri Oct 06, 2017 1:57 pm Post subject: |
|
|
Che faccio, provo a modificare /etc/grub.d/? |
|
Back to top |
|
|
zar Marco Guru
Joined: 09 Sep 2016 Posts: 445 Location: Colle Umberto ( TV )
|
Posted: Fri Oct 06, 2017 2:09 pm Post subject: |
|
|
Maxxx wrote: | Scusa, mi faresti una prova?
Dimmi l'output di
Code: | ls -al /dev/desk/by-uuid |
da chroot su sdb1 |
Code: | (chroot) root@hptoo $ ls -al /dev/sdb1 /by-uuid
ls: cannot access '/by-uuid': File o directory non esistente
brw-rw---- 1 root disk 8, 17 ott 6 15:13 /dev/sdb1
|
Ma notavo che ho in noatime tutti i dischi, ma è così pure da dove sto scrivendo |
|
Back to top |
|
|
Maxxx Guru
Joined: 12 Jan 2016 Posts: 595 Location: Italia
|
Posted: Fri Oct 06, 2017 2:15 pm Post subject: |
|
|
Provo a fare il punto della situazione:
In pratica il backup di sdb2 ha salvato su sdb1 gli stessi file, tra cui il file /etc/fstab che quindi, essendo stato copiato da sdb2, contiene l'UUID di sdb2 (e non di sdb1)... a conferma di ciò, per vedere il vero UUID di sdb1 (che non sia uguale a quello del file fstab) lanciare
Code: | ls -al /dev/desk/by-uuid |
Il fatto che su fstab di sdb1 hai sostituito l'UUID con il reale device, avrebbe dovuto togliere ogni dubbio, invece non parte lo stesso e mi viene il sospetto che forse è proprio quell'opzione "noauto" che dovrebbe diventare "defaults"... ma se sdb2 si avvia lo stesso con l'opzione "noauto", da cosa può dipendere?
Per ora non mi viene in mente niente, se non di provare a vedere il reale UUID di sdb1 e metterlo su fstab di sdb1 con l'opzione "defaults" sul device /boot... secondo me è da provare. |
|
Back to top |
|
|
Maxxx Guru
Joined: 12 Jan 2016 Posts: 595 Location: Italia
|
Posted: Fri Oct 06, 2017 2:16 pm Post subject: |
|
|
Non
Code: | ls -al /dev/sdb1 /by-uuid |
ma
Code: | ls -al /dev/sdb1/by-uuid |
togli lo spazio dopo sdb1 |
|
Back to top |
|
|
zar Marco Guru
Joined: 09 Sep 2016 Posts: 445 Location: Colle Umberto ( TV )
|
Posted: Fri Oct 06, 2017 2:17 pm Post subject: |
|
|
Code: | (chroot) root@hptoo $ ls -al /dev/sdb1/by-uuid
ls: cannot access '/dev/sdb1/by-uuid': Non è una directory
|
Non mi restituisce niente |
|
Back to top |
|
|
Maxxx Guru
Joined: 12 Jan 2016 Posts: 595 Location: Italia
|
Posted: Fri Oct 06, 2017 2:22 pm Post subject: |
|
|
Code: | ls -al /dev/disk/by-uuid |
scusa /dev/disk/by-uuid |
|
Back to top |
|
|
zar Marco Guru
Joined: 09 Sep 2016 Posts: 445 Location: Colle Umberto ( TV )
|
Posted: Fri Oct 06, 2017 2:35 pm Post subject: |
|
|
Code: | (chroot) root@hptoo $ ls -al /dev/disk/by-uuid
total 0
drwxr-xr-x 2 root root 220 ott 6 15:13 .
drwxr-xr-x 8 root root 160 ott 6 15:12 ..
lrwxrwxrwx 1 root root 10 ott 6 15:13 1A8E424E8E42229D -> ../../sda4
lrwxrwxrwx 1 root root 10 ott 6 15:13 1d596c35-2e8d-4796-9a19-83770e497450 -> ../../sda6
lrwxrwxrwx 1 root root 9 ott 6 15:13 2016-10-02-07-25-26-00 -> ../../sr0
lrwxrwxrwx 1 root root 10 ott 6 15:13 254cbe70-ff7d-47e4-9a6a-e6a771ba66eb -> ../../sdb1
lrwxrwxrwx 1 root root 10 ott 6 15:13 36AA5469AA54281F -> ../../sda3
lrwxrwxrwx 1 root root 10 ott 6 15:13 5849d6b6-3410-41d1-a1ec-a3cb9f78a9e8 -> ../../sda7
lrwxrwxrwx 1 root root 10 ott 6 15:13 5B81-1818 -> ../../sda8
lrwxrwxrwx 1 root root 10 ott 6 15:13 780877050876C1A4 -> ../../sda5
lrwxrwxrwx 1 root root 10 ott 6 15:13 D224-521F -> ../../sda1
|
Ecco, ora ci siamo, ma non segna tutte le partizioni |
|
Back to top |
|
|
Maxxx Guru
Joined: 12 Jan 2016 Posts: 595 Location: Italia
|
Posted: Fri Oct 06, 2017 2:41 pm Post subject: |
|
|
Grub punta a sdb1, l'UUID è quello, che però è anche quello di sdb2... e se provi a mettere l'opzione "defaults" su fstab di /boot di sdb1?
Altrimenti non mi viene in mente altro... mi dispiace.
Al limite puoi provare a postare sul forum internazionale, lì sicuramente troverai risposta. |
|
Back to top |
|
|
Maxxx Guru
Joined: 12 Jan 2016 Posts: 595 Location: Italia
|
Posted: Fri Oct 06, 2017 2:54 pm Post subject: |
|
|
Un'altra prova che farei, sempre dentro sdb1, è ricreare automaticamente il file grub.cfg dando il comando
Code: | grub-mkconfig -o /boot/grub/grub.cfg |
come utente root
Per fare questo, però la cartella /boot deve essere montata. |
|
Back to top |
|
|
zar Marco Guru
Joined: 09 Sep 2016 Posts: 445 Location: Colle Umberto ( TV )
|
Posted: Fri Oct 06, 2017 2:55 pm Post subject: |
|
|
Grazie, intanto ho scritto sul forum internazionale, speriamo.
Riguardo al cambiare fstab, perché quindi / home e swap si caricano anche se in fstab sono in noatime? |
|
Back to top |
|
|
Maxxx Guru
Joined: 12 Jan 2016 Posts: 595 Location: Italia
|
Posted: Fri Oct 06, 2017 3:02 pm Post subject: |
|
|
Non è il noatime, ma il noauto...
Code: | ...
UUID=D224-521F /boot/efi vfat noauto,noatime 1 2
... |
comunque alla fine non sarà nemmeno quello, perchè anche su sdb2 è così ma si avvia lo stesso |
|
Back to top |
|
|
zar Marco Guru
Joined: 09 Sep 2016 Posts: 445 Location: Colle Umberto ( TV )
|
Posted: Fri Oct 06, 2017 3:17 pm Post subject: |
|
|
mah, causa mancanza di tempo, fino a lunedì non tocco più, intanto grazie mille, con l'inizio di settimana prossima tornerò a pensarci |
|
Back to top |
|
|
Maxxx Guru
Joined: 12 Jan 2016 Posts: 595 Location: Italia
|
Posted: Fri Oct 06, 2017 3:28 pm Post subject: |
|
|
Scusami se torno indietro di qualche post, ma come ti avevo già detto non sono molto ferrato di Grub... stavo proprio ora leggendo un'altra cosa rispetto a quello che ti avevo detto prima, ovvero che per Grub anche le partizioni partono dal numero zero, quindi potresti avere avuto ragione tu dicendo di provare a cambiare "hd1,msdos1" in "hd1,msdos0" sul file grub.cfg, così da poter essere sdb1. |
|
Back to top |
|
|
zar Marco Guru
Joined: 09 Sep 2016 Posts: 445 Location: Colle Umberto ( TV )
|
Posted: Fri Oct 06, 2017 4:00 pm Post subject: |
|
|
Ormai non ci do più fuori. Ho cercato in tutti i file dentro ad /etc/grub.d ma no riesco a capire dove devo cambiare |
|
Back to top |
|
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|