Results 1 to 1 of 1
Hi,
it's been two days (and nights) I'm trying to set up my dreamplug (that was working fine up to now) to act as a router; basically I'd like to ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
- 08-27-2012 #1Just Joined!
- Join Date
- Aug 2012
- Posts
- 1
Filesystem corruption on Dreamplug when used as router
Hi,
it's been two days (and nights) I'm trying to set up my dreamplug (that was working fine up to now) to act as a router; basically I'd like to connect my windows PC to eth0 being able to see the SAMBA share I created on the USB disk connected to the Dreamplug. I'd also like to be able to connect to the Internet from the above Windows PC connected to eth0
so:
eth0: connected to my Windows PC wired
eth1: connected to the Internet and gets the IP address from my router via DHCP
Wifi: disabled
I'm using Debian Wheezy.
Following some posts around I modified /etc/network/interfaces, initSetup.sh, sysctl.conf as follow:
interfaces:
initSetup.sh:Code:auto lo iface lo inet loopback auto eth0 iface eth0 inet static address 192.168.5.1 network 192.168.5.0 netmask 255.255.255.0 broadcast 192.168.5.255 auto eth1 iface eth1 inet dhcp
sysctl.conf:Code:iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE iptables -t nat -A POSTROUTING -o eth1 -j MASQUERADE /etc/init.d/udhcpd start # start DHCP server # Set leds echo 1 > `eval ls /sys/class/leds/guruplug\:green\:wmode/brightness` echo 0 > `eval ls /sys/class/leds/guruplug\:red\:wmode/brightness`
udhcpd.conf:Code:vm.swappiness=0 vm.laptop_mode=5 vm.dirty_writeback_centisecs=1000 vm.dirty_expire_centisecs=1000 net.ipv4.ip_forward=1
I also installed bind9 to share the DNS with my Windows PC connected to eth0 (I also removed it just to check if the problem lied there)Code:start 192.168.5.100 end 192.168.5.200 interface eth0 opt lease 86400 opt router 192.168.5.1 opt subnet 255.255.255.0 opt dns 192.168.5.1 opt domain localdomain max_leases 101 lease_file /var/lib/udhcpd.leases auto_time 5
eth1 works fine, gets the IP address from my ISP Router and connects to the Internet
Problem:
Whenever I connect a LAN cable to eth0 (my Windows PC on the other side):
a) the PC does not get an IP address no matter how many times I restart udhcpd or the networking service
b) filesystem gets immediately corrupted, I cannot access files in etc/ and in many other locations, I have to take out the Dreamplug internal SD, insert it in my Ubuntu PC and run e2fsck in order to fix all the problems it finds. If I don't do ths the Dreamplug is not able to restart. the problems e2fsck finds are (just a few lines):
I'm really stuck here, anybody has any idea about why it is happening and how I can fix the problem and configure the Dreamplug as a router?Code:e2fsck 1.41.11 (14-Mar-2010) e2fsck: Group descriptors look bad... trying backup blocks... Superblock needs_recovery flag is clear, but journal has data. Recovery flag not set in backup superblock, so running journal anyway. dp-rootfs: recovering journal Resize inode not valid. Recreate<y>? yes Pass 1: Checking inodes, blocks, and sizes Pass 2: Checking directory structure Pass 3: Checking directory connectivity Pass 4: Checking reference counts Pass 5: Checking group summary information Free blocks count wrong for group #0 (31778, counted=31779). Fix<y>? yes Free blocks count wrong for group #1 (31428, counted=30973). Fix<y>? yes Free blocks count wrong for group #2 (31359, counted=30947). Fix<y>? yes Free blocks count wrong for group #4 (21905, counted=19898). Fix<y>? yes Free blocks count wrong for group #5 (22939, counted=9928). Fix<y>? yes Free blocks count wrong for group #6 (25060, counted=28039). Fix<y>? yes ....
Thank you very much in advance for your help!!
Marco


Reply With Quote
