Jump to content
Omega16

Partitie Linux stricata

Recommended Posts

Salut.

Un amic a incercat sa modifice niste partitii pe un CentOS astfel: sa "ia" 50 GB de la /home si sa-i adauge la /root.

Nu stiu exact ce comenzi a folosit, in orice caz, a facut dupa un tutorial de pe net. Din cate m-am uitat eu, nu a modificat si file systemul.

Acum /home da erori si sistemul nu mai porneste. Am reusit totusi sa-l pornesc, prin editarea fstab si comentarea liniei aferenta /home.

root@web [/home]# fsck.ext4 -v /dev/mapper/vg_web-lv_home

e2fsck 1.41.12 (17-May-2010)

The filesystem size (according to the superblock) is 195463168 blocks

The physical size of the device is 182093824 blocks

Either the superblock or the partition table is likely to be corrupt!

Abort<y>? no

/dev/mapper/vg_web-lv_home contains a file system with errors, check forced.

Pass 1: Checking inodes, blocks, and sizes

Error reading block 183500832 (Invalid argument) while getting next inode from scan. Ignore error<y>? yes

Force rewrite<y>? yes

Error writing block 183500832 (Invalid argument) while getting next inode from scan. Ignore error<y>? yes

Error reading block 183500833 (Invalid argument) while getting next inode from scan. Ignore error<y>? yes

Force rewrite<y>? yes

Error reading block 184549408 (Invalid argument) while getting next inode from scan. Ignore error<y>? no

Error while scanning inodes (45875236): Can't read next inode

e2fsck: aborted

Si tot asa.....De aici, am tot cauta pe net cum sa pot rezolva, dar nimic nu merge.

Vreo idee?

Multumesc

Link to comment
Share on other sites

Am rezolvat problema astfel:

1. Am facut backup cu utilitarul TestDisk (foarte bun, recomand), salvand datele pe alt HDD.

2. Am sters logical volume pe care era /home si l-am recreat.

3. Am copiat datele salvate anterior pe /home.

Asta a fost doar o alternativa, insa repararea "volumului logic" nu a reusit in niciun fel. Toate comenzile conduceau la rezultatul: "The filesystem size (according to the superblock) is 195463168 blocks

The physical size of the device is 182093824 blocks

Either the superblock or the partition table is likely to be corrupt!".

Daca totusi ii s-a intamplat cuiva si a reusit sa-l repare fara sa piarda datele, sa ne spuna si noua. Cine stie cand are careva nevoie.

Multumesc

Link to comment
Share on other sites

Salutare,

In cazul de fata problema pare a fi ca a micsorat logical volume-ul inainte sa micsoreze filesystem-ul. Dupa cum afiseaza si eroarea, filesystem size-ul e mai mare decat physical size of the device.

Ai fi putut sa incerci sa micsorezi filesystem-ul cu

resize2fs
si sa incerci apoi sa remontezi home-ul.

Pasii corecti de urmat in cazul in care vrei sa faci operatiunea asta sunt urmatorii:

1. Demontare filesystem -

umount /home

2. Verificare filesystem de erori -

fsck -f /dev/mapper/vg_web-lv_home

3. Redimensionare filesystem pe care sta /home -

resize2fs /dev/mapper/vg_web-lv_home dimensiune noua disc

4. Redimensionare logical volume -

lvchange -L DimensiuneNouaG /dev/mapper/vg_web-lv_home

Apoi poti remonta filesystemul.

L.E. Am adaugat in exemple LV-ul tau, in loc de unul generic.

Edited by eyeheartpi
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.



×
×
  • Create New...