01.05.2025, 13:24 UhrDeutsch | English
Hallo Gast [ Registrierung | Anmelden ]

Neues Thema eröffnen   Neue Antwort erstellen
Vorheriges Thema anzeigen Druckerfreundliche Version Einloggen, um private Nachrichten zu lesen Nächstes Thema anzeigen
Autor Nachricht
sk11
22 Titel: fstab file  BeitragVerfasst am: 15.11.2006, 19:52 Uhr



Anmeldung: 12. Aug 2006
Beiträge: 19

I have an external usb HD, with several partitions on it. Here is a print out of my fstab file:
Code:

# /etc/fstab: static file system information.
#
# <file system> <mount point>   <type>  <options>       <dump>  <pass>
proc            /proc           proc    defaults        0       0
usbfs  /proc/bus/usb  usbfs  devmode=0666  0  0
/dev/hda6       /               ext3    defaults,errors=remount-ro 0       1
/dev/hda5       /home           ext3    defaults        0       2
/dev/hda1       /media/hda1     ntfs    ro,umask=000    0       0
/dev/hda7       none            swap    sw              0       0
/dev/sdb1       /media/flash    auto    defaults,rw,user,noauto  0      0
/dev/sda1       /media/h1       ntfs    noauto,users,exec,ro,umask=000 0       0
/dev/sda3       /media/h3    vfat    noauto,users,exec,umask=000,shortname=mixed,quiet 0       0
/dev/sda5       /media/h5      ext3    noauto,users,exec 0       0
/dev/sda6       /media/h6     ext3    noauto,users,exec 0       0
/dev/cdrom      /media/cdrw     udf,iso9660 user,noauto     0       0
none /sys sysfs defaults 0 0


Sometimes, the partitions get linked as sdbx instead of sdax, I then have to alter my fstab file accordingly and mount each of the partitions. This happens very regularly, at random. Is there no way to make it permanently stick with either sdax or sdbx?
 
 Benutzer-Profile anzeigen Private Nachricht senden  
Antworten mit Zitat Nach oben
slh
Titel: RE: fstab file  BeitragVerfasst am: 15.11.2006, 20:23 Uhr



Anmeldung: 16. Aug 2004
Beiträge: 1905

You could use /dev/disk/by-id/* for fstab.
 
 Benutzer-Profile anzeigen Private Nachricht senden  
Antworten mit Zitat Nach oben
h2
Titel: RE: fstab file  BeitragVerfasst am: 15.11.2006, 21:19 Uhr



Anmeldung: 12. Mar 2005
Beiträge: 1005

Found a nice how to for labels, uuid, id stuff. Sometimes the ubuntu guys come through with some nice documentation, this is one of those times, that page pretty much covers everything you need to know.

_________________
Read more on dist-upgrades using du-fixes-h2.sh script.
New: rdiff-backup script
 
 Benutzer-Profile anzeigen Private Nachricht senden  
Antworten mit Zitat Nach oben
sk11
Titel: RE: fstab file  BeitragVerfasst am: 15.11.2006, 21:56 Uhr



Anmeldung: 12. Aug 2006
Beiträge: 19

The /dev/disks/by-label dir is missing partitions h5 and h6, so I tried to rectify this using:

Code:

umount /media/h5
mke2fs -L h5 /dev/sda5


No new labels appeared in /dev/disks/by-label and I'm now no longer able to mount h5, the error message I get is:

Code:

mount: wrong fs type, bad option, bad superblock on /dev/sda5,
       missing codepage or other error


According to syslog:
Code:

kernel: ext3: No journal on filesystem on sda5
 
 Benutzer-Profile anzeigen Private Nachricht senden  
Antworten mit Zitat Nach oben
mzilikazi
Titel: Re: RE: fstab file  BeitragVerfasst am: 15.11.2006, 22:34 Uhr
Team Member
Team Member


Anmeldung: 17. Dez 2003
Beiträge: 1109
Wohnort: Ganymede
sk11 hat folgendes geschrieben::
The /dev/disks/by-label dir is missing partitions h5 and h6, so I tried to rectify this using:

Code:

umount /media/h5
mke2fs -L h5 /dev/sda5


No new labels appeared in /dev/disks/by-label and I'm now no longer able to mount h5, the error message I get is:

Code:

mount: wrong fs type, bad option, bad superblock on /dev/sda5,
       missing codepage or other error


According to syslog:
Code:

kernel: ext3: No journal on filesystem on sda5


For ext3 the syntax is:
Code:
mke2fs -j

_________________
Ubuntu - An ancient African word for "Can't install Debian"
 
 Benutzer-Profile anzeigen Private Nachricht senden E-Mail senden Website dieses Benutzers besuchen  
Antworten mit Zitat Nach oben
sk11
Titel: RE: Re: RE: fstab file  BeitragVerfasst am: 15.11.2006, 23:34 Uhr



Anmeldung: 12. Aug 2006
Beiträge: 19

OH shit, I used mke2fs and mounted h5 only to find nothing on it!!! Tell me I didn't just wipe a whole 100G of data that wasn't backed up!!!
 
 Benutzer-Profile anzeigen Private Nachricht senden  
Antworten mit Zitat Nach oben
Crest
Titel: RE: Re: RE: fstab file  BeitragVerfasst am: 16.11.2006, 01:14 Uhr



Anmeldung: 03. Okt 2006
Beiträge: 415
Wohnort: Berlin
Smells like serious trouble.
 
 Benutzer-Profile anzeigen Private Nachricht senden Website dieses Benutzers besuchen  
Antworten mit Zitat Nach oben
h2
Titel: RE: Re: RE: fstab file  BeitragVerfasst am: 16.11.2006, 02:36 Uhr



Anmeldung: 12. Mar 2005
Beiträge: 1005

http://www.cgsecurity.org/wiki/TestDisk

try that, should be installed already, testdisk.
man testdisk for more information on how to use it.

In the future, I would avoid using command line partition tools as root until you actually understand what they do. Labeling, as for example gparted will tell you before you click ok, will destroy all the data on the partition. Well, I doubt it destroy it, it just changes the partition table, which I think testdisk will let you recover if you don't do too many more other things.

However, read up on the tool you use BEFORE you use it, or you may not be able to recover your data at all.

testdisk may recover it, I don't know, never used it.
http://www.tldp.org/HOWTO/Partition/recovering.html

_________________
Read more on dist-upgrades using du-fixes-h2.sh script.
New: rdiff-backup script
 
 Benutzer-Profile anzeigen Private Nachricht senden  
Antworten mit Zitat Nach oben
Beiträge vom vorherigen Thema anzeigen:     
Gehe zu:  
Alle Zeiten sind GMT + 1 Stunde
Neues Thema eröffnen   Neue Antwort erstellen
Vorheriges Thema anzeigen Druckerfreundliche Version Einloggen, um private Nachrichten zu lesen Nächstes Thema anzeigen
PNphpBB2 © 2003-2007 
 
Deutsch | English
Logos and trademarks are the property of their respective owners, comments are property of their posters, the rest is © 2004 - 2006 by Jörg Schirottke (Kano).
Consult Impressum and Legal Terms for details. Kanotix is Free Software released under the GNU/GPL license.
This CMS is powered by PostNuke, all themes used at this site are released under the GNU/GPL license. designed and hosted by w3you. Our web server is running on Kanotix64-2006.