Koozali.org: home of the SME Server

Need a little help with usb drive mount

Offline tviles

  • *****
  • 197
  • +0/-0
Need a little help with usb drive mount
« on: September 22, 2011, 03:27:57 AM »
I recently had a server go down with hard drive failure. I replaced hard drive and loaded it back up with sme version 8 but cannot
get the usb drive to mount. sdi is the external hard drive with data still on it that I need. The usb drive
was unplugged during the reloading of the server. In the log file I see a few messages about usb drives but cannot understand them.
I am trying to mount usb drive to /media/usbdevice then use MC to later on to retrieve the files. Then I need to put this usb drive back
as the backup device.

Using username "root".
root@192.168.13.1's password:
Last login: Wed Sep 21 19:54:48 2011 from pc-00250.shpdserver.local
[root@shpdserver ~]# df -T
Filesystem    Type   1K-blocks      Used Available Use% Mounted on
/dev/mapper/main-root
              ext3   133377232   2469920 124022756   2% /
/dev/md1      ext3      101018     25373     70429  27% /boot
tmpfs        tmpfs     1037508         0   1037508   0% /dev/shm
/dev/sda1     ext3   961432072 170020720 742573352  19% /home/e-smith/files/ibays/police/files
[root@shpdserver ~]# df -h
Filesystem            Size  Used Avail Use% Mounted on
/dev/mapper/main-root
                      128G  2.4G  119G   2% /
/dev/md1               99M   25M   69M  27% /boot
tmpfs                1014M     0 1014M   0% /dev/shm
/dev/sda1             917G  163G  709G  19% /home/e-smith/files/ibays/police/files
[root@shpdserver ~]# fdisk -l

Disk /dev/sda: 1000.2 GB, 1000204886016 bytes
255 heads, 63 sectors/track, 121601 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1               1      121601   976760001   83  Linux

Disk /dev/sdb: 36.4 GB, 36420075008 bytes
255 heads, 63 sectors/track, 4427 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System
/dev/sdb1   *           1          13      104391   fd  Linux raid autodetect
/dev/sdb2              14        4427    35455455   fd  Linux raid autodetect

Disk /dev/sdc: 36.4 GB, 36420075008 bytes
255 heads, 63 sectors/track, 4427 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System
/dev/sdc1   *           1          13      104391   fd  Linux raid autodetect
/dev/sdc2              14        4427    35455455   fd  Linux raid autodetect

Disk /dev/sdd: 36.4 GB, 36420075008 bytes
255 heads, 63 sectors/track, 4427 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System
/dev/sdd1   *           1          13      104391   fd  Linux raid autodetect
/dev/sdd2              14        4427    35455455   fd  Linux raid autodetect

Disk /dev/sde: 36.4 GB, 36420075008 bytes
255 heads, 63 sectors/track, 4427 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System
/dev/sde1   *           1          13      104391   fd  Linux raid autodetect
/dev/sde2              14        4427    35455455   fd  Linux raid autodetect

Disk /dev/sdf: 73.5 GB, 73543163904 bytes
255 heads, 63 sectors/track, 8941 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System
/dev/sdf1   *           1          13      104391   fd  Linux raid autodetect
/dev/sdf2              14        8941    71714160   fd  Linux raid autodetect

Disk /dev/sdg: 73.4 GB, 73407820800 bytes
255 heads, 63 sectors/track, 8924 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System
/dev/sdg1   *           1          13      104391   fd  Linux raid autodetect
/dev/sdg2              14        8924    71577607+  fd  Linux raid autodetect

Disk /dev/md2: 145.2 GB, 145224630272 bytes
2 heads, 4 sectors/track, 35455232 cylinders
Units = cylinders of 8 * 512 = 4096 bytes

Disk /dev/md2 doesn't contain a valid partition table

Disk /dev/md1: 106 MB, 106823680 bytes
2 heads, 4 sectors/track, 26080 cylinders
Units = cylinders of 8 * 512 = 4096 bytes

Disk /dev/md1 doesn't contain a valid partition table

Disk /dev/sdi: 1000.2 GB, 1000204886016 bytes
255 heads, 63 sectors/track, 121601 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System
/dev/sdi1   *           1          13      104391   fd  Linux raid autodetect
/dev/sdi2              14      121601   976655610   fd  Linux raid autodetect
[root@shpdserver ~]#


[root@shpdserver ~]# nano /etc/fstab
  GNU nano 1.3.12                                           File: /etc/fstab

#------------------------------------------------------------
# BE CAREFUL WHEN MODIFYING THIS FILE! It is updated automatically
# by the SME server software. A few entries are updated during
# the template processing of the file and white space is removed,
# but otherwise changes to the file are preserved.
# For more information, see http://www.e-smith.org/custom/ and
# the template fragments in /etc/e-smith/templates/etc/fstab/.
#
# copyright (C) 2002 Mitel Networks Corporation
#------------------------------------------------------------
/dev/main/root          /                       ext3    usrquota,grpquota        1 1
/dev/md1                /boot                   ext3    defaults        1 2
tmpfs                   /dev/shm                tmpfs   defaults        0 0
devpts                  /dev/pts                devpts  gid=5,mode=620  0 0
sysfs                   /sys                    sysfs   defaults        0 0
proc                    /proc                   proc    defaults        0 0
/dev/main/swap          swap                    swap    defaults        0 0
/dev/sda1               /home/e-smith/files/ibays/police/files                   ext3    defaults        0 0

View log files
 

/var/log/messages: Viewed at Wed 21 Sep 2011 07:50:31 PM CDT.Sep 19 13:57:29 shpdserver syslogd 1.4.1: restart.
Sep 19 13:57:29 shpdserver kernel: klogd 1.4.1, log source = /proc/kmsg started.
Sep 19 13:57:29 shpdserver kernel: Inspecting /boot/System.map-2.6.18-274.3.1.el5
Sep 19 13:57:29 shpdserver kernel: Loaded 30551 symbols from /boot/System.map-2.6.18-274.3.1.el5.
Sep 19 13:57:29 shpdserver kernel: Symbols match kernel version 2.6.18.
Sep 19 13:57:29 shpdserver kernel: No module symbols loaded - kernel modules not enabled.
Sep 19 13:57:29 shpdserver kernel: Linux version 2.6.18-274.3.1.el5 (mockbuild@builder10.centos.org) (gcc version 4.1.2 20080704 (Red Hat 4.1.2-51)) #1 SMP Tue Sep 6 20:14:03 EDT 2011
Sep 19 13:57:29 shpdserver kernel: BIOS-provided physical RAM map:
Sep 19 13:57:29 shpdserver kernel:  BIOS-e820: 0000000000010000 - 00000000000a0000 (usable)
Sep 19 13:57:29 shpdserver kernel:  BIOS-e820: 0000000000100000 - 000000007fff0000 (usable)
Sep 19 13:57:29 shpdserver kernel:  BIOS-e820: 000000007fff0000 - 000000007fffec00 (ACPI data)
Sep 19 13:57:29 shpdserver kernel:  BIOS-e820: 000000007fffec00 - 000000007ffff000 (reserved)
Sep 19 13:57:29 shpdserver kernel:  BIOS-e820: 00000000fec00000 - 00000000fec10000 (reserved)
Sep 19 13:57:29 shpdserver kernel:  BIOS-e820: 00000000fee00000 - 00000000fee10000 (reserved)
Sep 19 13:57:30 shpdserver kernel:  BIOS-e820: 00000000fff80000 - 0000000100000000 (reserved)
Sep 19 13:57:30 shpdserver kernel: 1151MB HIGHMEM available.
Sep 19 13:57:30 shpdserver kernel: 896MB LOWMEM available.
Sep 19 13:57:30 shpdserver kernel: found SMP MP-table at 000fe710
Sep 19 13:57:30 shpdserver kernel: Memory for crash kernel (0x0 to 0x0) notwithin permissible range
Sep 19 13:57:30 shpdserver kernel: disabling kdump
Sep 19 13:57:30 shpdserver kernel: Using x86 segment limits to approximate NX protection
Sep 19 13:57:30 shpdserver kernel: On node 0 totalpages: 524272
Sep 19 13:57:30 shpdserver kernel:   DMA zone: 4096 pages, LIFO batch:0
Sep 19 13:57:30 shpdserver kernel:   Normal zone: 225280 pages, LIFO batch:31
Sep 19 13:57:30 shpdserver kernel:   HighMem zone: 294896 pages, LIFO batch:31
Sep 19 13:57:30 shpdserver kernel: DMI 2.3 present.
Sep 19 13:57:30 shpdserver kernel: DMI: Dell Computer Corporation PowerEdge 2500             , BIOS A07 08/15/2003
Sep 19 13:57:30 shpdserver kernel: Using APIC driver default
Sep 19 13:57:31 shpdserver kernel: ACPI: RSDP (v000 DELL                                  ) @ 0x000fdc80
Sep 19 13:57:31 shpdserver kernel: ACPI: RSDT (v001 DELL   PE2500   0x00000001 MSFT 0x0100000a) @ 0x000fdc94
Sep 19 13:57:31 shpdserver kernel: ACPI: FADT (v001 DELL   PE2500   0x00000001 MSFT 0x0100000a) @ 0x000fdcc4
Sep 19 13:57:31 shpdserver kernel: ACPI: MADT (v001 DELL   PE2500   0x00000001 MSFT 0x0100000a) @ 0x000fdd38
Sep 19 13:57:31 shpdserver kernel: ACPI: SPCR (v001 DELL   PE2500   0x00000001 MSFT 0x0100000a) @ 0x000fdd98
Sep 19 13:57:31 shpdserver kernel: ACPI: DSDT (v001 DELL   PE2500   0x00000001 MSFT 0x0100000a) @ 0x00000000
Sep 19 13:57:31 shpdserver kernel: ACPI: PM-Timer IO Port: 0x808
Sep 19 13:57:31 shpdserver kernel: ACPI: Local APIC address 0xfee00000
Sep 19 13:57:31 shpdserver kernel: ACPI: LAPIC (acpi_id[0x01] lapic_id[0x01] enabled)
Sep 19 13:57:31 shpdserver kernel: Processor #1 6:11 APIC version 17
Sep 19 13:57:31 shpdserver kernel: ACPI: LAPIC (acpi_id[0x02] lapic_id[0x00] enabled)
Sep 19 13:57:31 shpdserver kernel: Processor #0 6:11 APIC version 17
Sep 19 13:57:31 shpdserver kernel: ACPI: LAPIC_NMI (acpi_id[0x01] high edge lint[0x1])
Sep 19 13:57:31 shpdserver kernel: ACPI: LAPIC_NMI (acpi_id[0x02] high edge lint[0x1])
Sep 19 13:57:31 shpdserver kernel: ACPI: IOAPIC (id[0x02] address[0xfec00000] gsi_base[0])
Sep 19 13:57:31 shpdserver kernel: IOAPIC[0]: apic_id 2, version 17, address 0xfec00000, GSI 0-15
Sep 19 13:57:31 shpdserver kernel: ACPI: IOAPIC (id[0x03] address[0xfec01000] gsi_base[16])
Sep 19 13:57:31 shpdserver /sbin/e-smith/bootstrap-console[1956]: /home/e-smith/db/configuration: OLD bootstrap-console=service|ForceSave|yes|Run|yes|status|enabled
Sep 19 13:57:31 shpdserver kernel: IOAPIC[1]: apic_id 3, version 17, address 0xfec01000, GSI 16-31
Sep 19 13:57:31 shpdserver /sbin/e-smith/bootstrap-console[1956]: /home/e-smith/db/configuration: NEW bootstrap-console=service|ForceSave|no|Run|yes|status|enabled
Sep 19 13:57:31 shpdserver kernel: ACPI: IRQ9 used by override.
Sep 19 13:57:31 shpdserver /sbin/e-smith/bootstrap-console[1956]: /home/e-smith/db/configuration: OLD bootstrap-console=service|ForceSave|no|Run|yes|status|enabled
Sep 19 13:57:31 shpdserver kernel: Enabling APIC mode:  Flat.  Using 2 I/O APICs
Sep 19 13:57:31 shpdserver /sbin/e-smith/bootstrap-console[1956]: /home/e-smith/db/configuration: NEW bootstrap-console=service|ForceSave|no|Run|no|status|enabled
Sep 19 13:57:31 shpdserver kernel: Using ACPI (MADT) for SMP configuration information
Sep 19 13:57:32 shpdserver kernel: Allocating PCI resources starting at 80000000 (gap: 7ffff000:7ec01000)
Sep 19 13:57:32 shpdserver kernel: Detected 1390.860 MHz processor.
Sep 19 13:57:32 shpdserver kernel: Built 1 zonelists.  Total pages: 524272
Sep 19 13:57:32 shpdserver kernel: Kernel command line: ro root=/dev/main/root
Sep 19 13:57:32 shpdserver kernel: mapped APIC to ffffd000 (fee00000)
Sep 19 13:57:32 shpdserver kernel: mapped IOAPIC to ffffc000 (fec00000)
Sep 19 13:57:32 shpdserver kernel: mapped IOAPIC to ffffb000 (fec01000)
Sep 19 13:57:32 shpdserver kernel: Enabling fast FPU save and restore... done.
Sep 19 13:57:32 shpdserver kernel: Enabling unmasked SIMD FPU exception support... done.
Sep 19 13:57:32 shpdserver kernel: Initializing CPU#0
Sep 19 13:57:32 shpdserver kernel: CPU 0 irqstacks, hard=c076f000 soft=c074f000
Sep 19 13:57:32 shpdserver kernel: PID hash table entries: 4096 (order: 12, 16384 bytes)
Sep 19 13:57:32 shpdserver kernel: Console: colour VGA+ 80x25
Sep 19 13:57:32 shpdserver kernel: Dentry cache hash table entries: 131072 (order: 7, 524288 bytes)
Sep 19 13:57:32 shpdserver kernel: Inode-cache hash table entries: 65536 (order: 6, 262144 bytes)
Sep 19 13:57:32 shpdserver kernel: Memory: 2070416k/2097088k available (2196k kernel code, 25368k reserved, 914k data, 232k init, 1179584k highmem)
Sep 19 13:57:32 shpdserver kernel: Checking if this processor honours the WP bit even in supervisor mode... Ok.
Sep 19 13:57:32 shpdserver kernel: Calibrating delay loop (skipped), value calculated using timer frequency.. 2781.72 BogoMIPS (lpj=1390860)
Sep 19 13:57:32 shpdserver esmith::event[1959]: Processing event: bootstrap-console-save 
Sep 19 13:57:32 shpdserver kernel: Security Framework v1.0.0 initialized
Sep 19 13:57:32 shpdserver esmith::event[1959]: Running event handler: /etc/e-smith/events/bootstrap-console-save/S00initialize-default-databases

--------------------------------------------------------------------------------
 SME Server 8.0beta6
Copyright 1999-2006 Mitel Corporation
All rights reserved.
Copyright 2006 SME Server, Inc.
 
Using username "root".
root@192.168.13.1's password:
Last login: Wed Sep 21 19:45:08 2011 from pc-00250.shpdserver.local
[root@shpdserver ~]# cd /media
[root@shpdserver media]# dir
usbdevice
[root@shpdserver media]# cd usbdevice
[root@shpdserver usbdevice]# dir
[root@shpdserver usbdevice]# cd /dev
[root@shpdserver dev]# dir
bus         kmsg      pts          sdc       stdin   tty32  tty6
cdrom       log       ram          sdc1      stdout  tty33  tty60
cdrom-hda   loop0     ram0         sdc2      systty  tty34  tty61
console     loop1     ram1         sdd       tty     tty35  tty62
core        loop2     ram10        sdd1      tty0    tty36  tty63
disk        loop3     ram11        sdd2      tty1    tty37  tty7
fd          loop4     ram12        sde       tty10   tty38  tty8
fd0         loop5     ram13        sde1      tty11   tty39  tty9
fd0u1040    loop6     ram14        sde2      tty12   tty4   ttyS0
fd0u1120    loop7     ram15        sdf       tty13   tty40  ttyS1
fd0u1440    lp0       ram2         sdf1      tty14   tty41  ttyS2
fd0u1680    main      ram3         sdf2      tty15   tty42  ttyS3
fd0u1722    MAKEDEV   ram4         sdg       tty16   tty43  urandom
fd0u1743    mapper    ram5         sdg1      tty17   tty44  usbdev1.1_ep00
fd0u1760    md0       ram6         sdg2      tty18   tty45  usbdev1.1_ep81
fd0u1840    md1       ram7         sdi       tty19   tty46  usbdev1.3_ep00
fd0u1920    md2       ram8         sdi1      tty2    tty47  usbdev1.3_ep81
fd0u360     mem       ram9         sdi2      tty20   tty48  usbdev1.5_ep00
fd0u720     net       ramdisk      sg0       tty21   tty49  usbdev1.5_ep02
fd0u800     null      random       sg1       tty22   tty5   usbdev1.5_ep81
fd0u820     nvram     rawctl       sg2       tty23   tty50  vcs
fd0u830     oldmem    root         sg3       tty24   tty51  vcs2
floppy      par0      rtc          sg4       tty25   tty52  vcs3
floppy-fd0  parport0  scanner      sg5       tty26   tty53  vcsa
full        parport1  scanner-sg7  sg6       tty27   tty54  vcsa2
hda         parport2  sda          sg7       tty28   tty55  vcsa3
hiddev0     parport3  sda1         sg8       tty29   tty56  X0R
hpet        port      sdb          shm       tty3    tty57  zero
initctl     ppp       sdb1         snapshot  tty30   tty58
input       ptmx      sdb2         stderr    tty31   tty59
[root@shpdserver dev]

Offline janet

  • *****
  • 4,812
  • +0/-0
Re: Need a little help with usb drive mount
« Reply #1 on: September 22, 2011, 04:54:10 AM »
tviles

Is sdi your external USB drive ?

It looks to me that sdi is part of the RAID array

Please tell us more about all the drives in the server, you said you just "replaced hard drive" as if to mean you replaced one drive, but there seem to be a lot of drives.

What does
cat /proc/mdstat show

What mount command are you using to mount the USB drive ?
Please search before asking, an answer may already exist.
The Search & other links to useful information are at top of Forum.

Offline tviles

  • *****
  • 197
  • +0/-0
Re: Need a little help with usb drive mount
« Reply #2 on: September 22, 2011, 05:45:25 AM »
Yes sdi is the external USB drive.
Well then I must have had it plugged in during reload of operating system?
Yes replaced one of the 6 internal scsi hard drives due to errors it was reporting and kernel panic.

Offline tviles

  • *****
  • 197
  • +0/-0
Re: Need a little help with usb drive mount
« Reply #3 on: September 22, 2011, 05:56:43 AM »
Using username "root".
root@192.168.13.1's password:
Last login: Wed Sep 21 20:02:33 2011 from pc-00250.shpdserver.local
[root@shpdserver ~]# cat /proc/mdstat
Personalities : [raid6] [raid5] [raid4] [raid1]
md1 : active raid1 sdb1[0] sdc1[1] sdd1[2] sde1[3] sdf1[4] sdg1[5] sdh1[7](F)
      104320 blocks [7/6] [UUUUUU_]

md2 : active raid6 sdh2[6](S) sdg2[5] sdf2[4] sde2[3] sdd2[2] sdc2[1] sdb2[0]
      141820928 blocks level 6, 256k chunk, algorithm 2 [6/6] [UUUUUU]

unused devices: <none>
[root@shpdserver ~]# nano /etc/fstab
  GNU nano 1.3.12                                           File: /etc/fstab

#------------------------------------------------------------
# BE CAREFUL WHEN MODIFYING THIS FILE! It is updated automatically
# by the SME server software. A few entries are updated during
# the template processing of the file and white space is removed,
# but otherwise changes to the file are preserved.
# For more information, see http://www.e-smith.org/custom/ and
# the template fragments in /etc/e-smith/templates/etc/fstab/.
#
# copyright (C) 2002 Mitel Networks Corporation
#------------------------------------------------------------
/dev/main/root          /                       ext3    usrquota,grpquota        1 1
/dev/md1                /boot                   ext3    defaults        1 2
tmpfs                   /dev/shm                tmpfs   defaults        0 0
devpts                  /dev/pts                devpts  gid=5,mode=620  0 0
sysfs                   /sys                    sysfs   defaults        0 0
proc                    /proc                   proc    defaults        0 0
/dev/main/swap          swap                    swap    defaults        0 0
/dev/sda1               /home/e-smith/files/ibays/police/files                   ext3    defaults        0 0
#/dev/sdi               /media/usbdevice        vfat    defaults        0 0



Offline janet

  • *****
  • 4,812
  • +0/-0
Re: Need a little help with usb drive mount
« Reply #4 on: September 22, 2011, 06:55:23 AM »
tviles

Quote
Well then I must have had it plugged in during reload of operating system?

Or earlier if you tried to rebuild the array using the console menu and the system "saw" the USB as a spare drive and added it to the array ???

You don't say what mount command you are using.

I think you will need to reformat the USB drive ideally as ext3 (refer USB howto), and then use
mount /media/usbdevice
Do you really want to use vfat, much better to use ext3 when using it as a backup device on sme server ?

As far as your data is concerned, I think it may be gone, but you could try mounting the drive and looking at what data is there.

You will need to unhash the last line in fstab, although sme should automatically add the correct fstab entry when the USB drive is connected.
Please restart your sme server.

Please search before asking, an answer may already exist.
The Search & other links to useful information are at top of Forum.

Offline tviles

  • *****
  • 197
  • +0/-0
Re: Need a little help with usb drive mount
« Reply #5 on: September 22, 2011, 01:20:22 PM »
I was using something like mount /dev/sdi1. It will return an error regarding bad fs if you try to mount sdi2.
I put that line in the mstab was trying ext3 and vfat.
It appears to me cat /proc/mdstat is currently showing a problem with sdh1.
No I was not trying any means of rebuilding the array. Although last night I did try to stop and add shd1 back in but got an error message.
Thanks for you help. I still don't have all the desktops added into the new domain yet so I might change things.

Offline tviles

  • *****
  • 197
  • +0/-0
Re: Need a little help with usb drive mount
« Reply #6 on: September 22, 2011, 01:26:08 PM »
I put that line in fstab I meant to say not mstab.