Jump to content

Usb Mount And Swap - Please Help


sawks

Recommended Posts

I hope someone can help, im following this guide:

http://forums.hak5.org/index.php?showtopic=25882

To mount the sdcard on my 3g dongle (3g part is working)

When I used the default :

config global automount

option from_fstab 1

option anon_mount 1

config global autoswap

option from_fstab 1

option anon_swap 0

config mount

option target /usb

option device /dev/sda1

option fstype ext4

option options rw,sync

option enabled 0

option enabled_fsck 0

config swap

option device /dev/sda2

option enabled 0

I get :

Filesystem 1K-blocks Used Available Use% Mounted on

rootfs 896 236 660 26% /

/dev/root 5376 5376 0 100% /rom

tmpfs 14764 136 14628 1% /tmp

tmpfs 512 0 512 0% /dev

/dev/mtdblock3 896 236 660 26% /overlay

overlayfs:/overlay 896 236 660 26% /

/dev/sda1 6896176 232068 6318160 4% /mnt/sda1

/dev/sda2 833284 28208 763304 4% /mnt/sda2

when i use the config in the guide:

config global automount

option from_fstab 1

option anon_mount 1

config global autoswap

option from_fstab 1

option anon_swap 1

config mount

option target /usb

option device /dev/sda1

option fstype ext4

option options rw,sync

option enabled 1

option enabled_fsck 0

config swap

option device /dev/sda2

option enabled 1

I get:

root@Pineapple:~# df

Filesystem 1K-blocks Used Available Use% Mounted on

rootfs 896 236 660 26% /

/dev/root 5376 5376 0 100% /rom

tmpfs 14764 104 14660 1% /tmp

tmpfs 512 0 512 0% /dev

/dev/mtdblock3 896 236 660 26% /overlay

overlayfs:/overlay 896 236 660 26% /

/dev/sda1 6896176 232068 6318160 4% /usb

/dev/sdb1 6896176 232068 6318160 4% /mnt/sdb1

/dev/sdb2 833284 28208 763304 4% /mnt/sdb2

what the heck? why did it swap the mount i wanted for swap to sdb2?

Any ideas?

root@Pineapple:~# mkswap /dev/sda2

/dev/sda2: No such file or directory

root@Pineapple:~# mkswap /dev/sdb2

/dev/sdb2: Device or resource busy

35.150000] RPC: Registered named UNIX socket transport module.

[ 35.150000] RPC: Registered udp transport module.

[ 35.160000] RPC: Registered tcp transport module.

[ 35.160000] RPC: Registered tcp NFSv4.1 backchannel transport module.

[ 35.430000] PPP generic driver version 2.4.2

[ 35.610000] ip_tables: © 2000-2006 Netfilter Core Team

[ 35.830000] NET: Registered protocol family 24

[ 35.960000] nf_conntrack version 0.5.0 (461 buckets, 1844 max)

[ 36.650000] usbcore: registered new interface driver ath9k_htc

[ 36.900000] usbcore: registered new interface driver usbserial

[ 36.900000] USB Serial support registered for generic

[ 36.910000] usbcore: registered new interface driver usbserial_generic

[ 36.920000] usbserial: USB Serial Driver core

[ 36.960000] usbcore: registered new interface driver cdc_ether

[ 37.070000] Error: Driver 'gpio-keys-polled' is already registered, aborting...

[ 37.180000] usbcore: registered new interface driver rndis_host

[ 37.310000] scsi 0:0:0:0: Attached scsi generic sg0 type 5

[ 37.310000] sd 1:0:0:0: Attached scsi generic sg1 type 0

[ 38.730000] Unable to find swap-space signature

[ 38.900000] EXT4-fs (sda1): mounted filesystem with ordered data mode. Opts: (null)

[ 39.050000] Unable to find swap-space signature

[ 40.580000] usb 1-1: USB disconnect, device number 2

[ 40.590000] sd 1:0:0:0: [sda] Synchronizing SCSI cache

[ 40.590000] sd 1:0:0:0: [sda] Result: hostbyte=0x01 driverbyte=0x00

[ 43.120000] device wlan0 entered promiscuous mode

[ 44.490000] usb 1-1: new high-speed USB device number 3 using ath79-ehci

[ 44.800000] scsi2 : usb-storage 1-1:1.5

[ 44.800000] scsi3 : usb-storage 1-1:1.6

[ 44.970000] device wlan0 left promiscuous mode

[ 44.980000] br-lan: port 1(wlan0) entering disabled state

[ 45.130000] device wlan0 entered promiscuous mode

[ 45.820000] scsi 2:0:0:0: CD-ROM HUAWEI Mass Storage 2.31 PQ: 0 ANSI: 2

[ 45.820000] scsi 2:0:0:0: Attached scsi generic sg0 type 5

[ 45.830000] scsi 3:0:0:0: Direct-Access HUAWEI TF CARD Storage PQ: 0 ANSI: 2

[ 45.840000] sd 3:0:0:0: Attached scsi generic sg1 type 0

[ 45.860000] sd 3:0:0:0: [sdb] 15523840 512-byte logical blocks: (7.94 GB/7.40 GiB)

[ 45.900000] sd 3:0:0:0: [sdb] Write Protect is off

[ 45.900000] sd 3:0:0:0: [sdb] Mode Sense: 0f 0e 00 00

[ 45.900000] sd 3:0:0:0: [sdb] Write cache: enabled, read cache: enabled, doesn't support DPO or FUA

[ 46.060000] sdb: sdb1 sdb2

[ 46.210000] sd 3:0:0:0: [sdb] Attached SCSI removable disk

[ 47.380000] Unable to find swap-space signature

[ 47.890000] Unable to find swap-space signature

[ 49.210000] Unable to find swap-space signature

[ 49.620000] Unable to find swap-space signature

[ 50.120000] Unable to find swap-space signature

[ 50.940000] device wlan0 left promiscuous mode

[ 50.940000] br-lan: port 1(wlan0) entering disabled state

[ 51.180000] Unable to find swap-space signature

[ 51.800000] device wlan0 entered promiscuous mode

[ 52.050000] ath: Failed to stop TX DMA, queues=0x001!

[ 54.210000] device wlan0 left promiscuous mode

[ 54.210000] br-lan: port 1(wlan0) entering disabled state

[ 54.460000] device eth0 entered promiscuous mode

[ 54.650000] device wlan0 entered promiscuous mode

[ 58.050000] br-lan: port 2(wlan0) entering forwarding state

[ 58.050000] br-lan: port 2(wlan0) entering forwarding state

[ 60.820000] Unable to find swap-space signature

[ 61.120000] EXT4-fs (sdb1): couldn't mount as ext3 due to feature incompatibilities

[ 61.130000] EXT4-fs (sdb1): couldn't mount as ext2 due to feature incompatibilities

[ 61.170000] EXT4-fs (sdb1): recovery complete

[ 61.170000] EXT4-fs (sdb1): mounted filesystem with ordered data mode. Opts: (null)

[ 61.430000] Unable to find swap-space signature

[ 61.730000] EXT4-fs (sdb2): couldn't mount as ext3 due to feature incompatibilities

[ 61.740000] EXT4-fs (sdb2): couldn't mount as ext2 due to feature incompatibilities

[ 61.770000] EXT4-fs (sdb2): mounted filesystem with ordered data mode. Opts: (null)

[ 73.080000] br-lan: port 2(wlan0) entering forwarding state

[ 367.190000] EXT4-fs error (device sda1): ext4_find_entry:935: inode #2: comm ash: reading directory lbl

Link to comment
Share on other sites

I tried reflash and still problems.

Its driving me insain.

If i reboot the pineapple and plug in the usb 3g dongle with sdcard, no trouble with the 2nd fstab config (from darrens howto)

Filesystem 1K-blocks Used Available Use% Mounted on

rootfs 896 228 668 25% /

/dev/root 5376 5376 0 100% /rom

tmpfs 14764 112 14652 1% /tmp

tmpfs 512 0 512 0% /dev

/dev/mtdblock3 896 228 668 25% /overlay

overlayfs:/overlay 896 228 668 25% /

/dev/sda1 6896176 232068 6318160 4% /usb

root@Pineapple:~# free

total used free shared buffers

Mem: 29524 21420 8104 0 2588

-/+ buffers: 18832 10692

Swap: 835444 0 835444

If I leave the 3g card in and reboot then i get :

root@Pineapple:~# df

Filesystem 1K-blocks Used Available Use% Mounted on

rootfs 896 228 668 25% /

/dev/root 5376 5376 0 100% /rom

tmpfs 14764 108 14656 1% /tmp

tmpfs 512 0 512 0% /dev

/dev/mtdblock3 896 228 668 25% /overlay

overlayfs:/overlay 896 228 668 25% /

/dev/sda1 6896176 232068 6318160 4% /usb

/dev/sdb1 6896176 232068 6318160 4% /mnt/sdb1

and /usb is unaccesable.

root@Pineapple:~# touch /usb/test

touch: /usb/test: Input/output error

root@Pineapple:~# touch /mnt/sdb1/test

root@Pineapple:~#

mount -a does nothing

Any ideas?

I dont want to have to take out the 3g dongle everytime i want to reboot.

Any help would be ace thank you.

*******FSTAB*******

config global automount

option from_fstab 1

option anon_mount 1

config global autoswap

option from_fstab 1

option anon_swap 1

config mount

option target /usb

option device /dev/sda1

option fstype ext4

option options rw,sync

option enabled 1

option enabled_fsck 0

config swap

option device /dev/sda2

option enabled 1

Link to comment
Share on other sites

Wow after hours of pulling my hair out i finally fixed it.

It seemed to try and mount the drives and then mount them again giving multiple mount points.

I put "sleep 10" in /etc/init.d/fstab file after "START=20" and this waits 10 seconds before mounting giving it time to settle in.

This has worked, so i can carry on setting up :) :)

Link to comment
Share on other sites

Thank you very much! I had to use "sleep 20" for it to work for me. What USB 3G modem are you using? I was unable to use the MicroSD card in the dongle but everytime I would boot with the 3G and another flash drive it would not work and this fixed it.

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.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...