Active Topics

 


Reply
Thread Tools
azad1top's Avatar
Posts: 84 | Thanked: 11 times | Joined on Aug 2012 @ iran
#11
I can not see any change


Before handling code

Code:

BusyBox v1.10.2 (Debian 3:1.10.2.legal-1osso30+0m5) built-in shell (ash) 
Enter 'help' for a list of built-in commands. 

~ $ mount 
rootfs on / type rootfs (rw) 
ubi0:rootfs on / type ubifs (rw,bulk_read,no_chk_data_crc) 
proc on /proc type proc (rw) 
sysfs on /sys type sysfs (rw) 
tmpfs on /tmp type tmpfs (rw,noatime,size=1024k) 
tmpfs on /var/run type tmpfs (rw,nosuid,noatime,size=256k,mode=755) 
none on /dev type tmpfs (rw,noatime,size=10240k,mode=755) 
devpts on /dev/pts type devpts (rw,gid=5,mode=620) 
tmpfs on /dev/shm type tmpfs (rw,nosuid,nodev,noatime,size=65536k) 
nodev on /sys/kernel/debug type debugfs (0) 
/dev/mmcblk0p1 on /home/user/MyDocs type vfat (rw,noauto,nodev,noexec,nosuid,noatime,nodiratime,utf8,uid=29999,shortname=mixed,dmask=000,fmask=0133,rodir) 
/dev/mmcblk1p1 on /media/mmc1 type vfat (rw,noauto,nodev,noexec,nosuid,noatime,nodiratime,utf8,uid=29999,shortname=mixed,dmask=000,fmask=0133,rodir) 
~ $ df -h 
Filesystem Size Used Available Use% Mounted on 
rootfs 227.9M 218.5M 5.2M 98% / 
ubi0:rootfs 227.9M 218.5M 5.2M 98% / 
tmpfs 1.0M 76.0k 948.0k 7% /tmp 
tmpfs 256.0k 72.0k 184.0k 28% /var/run 
none 10.0M 80.0k 9.9M 1% /dev 
tmpfs 64.0M 4.0k 64.0M 0% /dev/shm 
/dev/mmcblk0p1 21.2G 312.6M 20.9G 1% /home/user/MyDocs 
/dev/mmcblk1p1 3.7G 816.4M 2.9G 22% /media/mmc1 
~ $ free 
total used free shared buffers 
Mem: 245540 240672 4868 0 15212 
Swap: 786424 16620 769804 
Total: 1031964 257292 774672 
~ $

After beating now



Code:


BusyBox v1.10.2 (Debian 3:1.10.2.legal-1osso30+0m5) built-in shell (ash) 
Enter 'help' for a list of built-in commands. 

~ $ mount 
rootfs on / type rootfs (rw) 
ubi0:rootfs on / type ubifs (rw,bulk_read,no_chk_data_crc) 
proc on /proc type proc (rw) 
sysfs on /sys type sysfs (rw) 
tmpfs on /tmp type tmpfs (rw,noatime,size=1024k) 
tmpfs on /var/run type tmpfs (rw,nosuid,noatime,size=256k,mode=755) 
none on /dev type tmpfs (rw,noatime,size=10240k,mode=755) 
devpts on /dev/pts type devpts (rw,gid=5,mode=620) 
tmpfs on /dev/shm type tmpfs (rw,nosuid,nodev,noatime,size=65536k) 
nodev on /sys/kernel/debug type debugfs (0) 
/dev/mmcblk0p1 on /home/user/MyDocs type vfat (rw,noauto,nodev,noexec,nosuid,noatime,nodiratime,utf8,uid=29999,shortname=mixed,dmask=000,fmask=0133,rodir) 
/dev/mmcblk1p1 on /media/mmc1 type vfat (rw,noauto,nodev,noexec,nosuid,noatime,nodiratime,utf8,uid=29999,shortname=mixed,dmask=000,fmask=0133,rodir) 
~ $ df -h 
Filesystem Size Used Available Use% Mounted on 
rootfs 227.9M 218.3M 5.4M 98% / 
ubi0:rootfs 227.9M 218.3M 5.4M 98% / 
tmpfs 1.0M 80.0k 944.0k 8% /tmp 
tmpfs 256.0k 72.0k 184.0k 28% /var/run 
none 10.0M 80.0k 9.9M 1% /dev 
tmpfs 64.0M 4.0k 64.0M 0% /dev/shm 
/dev/mmcblk0p1 21.2G 312.6M 20.9G 1% /home/user/MyDocs 
/dev/mmcblk1p1 3.7G 816.4M 2.9G 22% /media/mmc1 
~ $ free 
total used free shared buffers 
Mem: 245540 211908 33632 0 18340 
Swap: 786424 0 786424 
Total: 1031964 211908 820056 
~ $


Nothing is wrong with that first change


Instead of working with a difficult Kjash still do not understand?

Last edited by azad1top; 2012-08-29 at 06:19.
 
Posts: 2,102 | Thanked: 1,937 times | Joined on Sep 2008 @ Berlin, Germany
#12
You now should have read/write access to the data partition again, from the output, but...
Flashing is not the solution for your device!!!You have no optfs partition mounted on your device. This is critical to space on your device.

Be careful not to skip any step or to continue ignoring errors! To repair damage you do now will be more difficult to cure, but still doable.

Please try to show the partition table to verify the optfs-partition is there with the right parameters
Code:
sudo gainroot
sfdisk -l
If there is an entry in the partition table looking like this (numbers will vary!)
/dev/mmcblk0p2 530496 817791 287296 9193472 83 Linux
start: (c,h,s) expected (1023,3,16) found (1023,63,32)
then do
Code:
sudo gainroot
fsck -af /dev/mmcblk0p2
This will check and try to repair the partition automatically. DO NOT REBOOT NOW! If errors occur post them here.
If no errors are been put out, continue
Code:
sudo gainroot
mount /dev/mmcblk0p2 /mnt
Now look into /mnt to verify the existence of /opt and /user folders in there, there is also lost+found. They should be there.
Code:
ls -al /mnt
Now
If you find those two folders there, continue with crating a backup of the folders on your external card for safety's reasons, then copy the folders and remove the folders
Code:
tar  -cvf /media/mmc1/opt.tar /opt
cp -avx /opt/* /mnt/opt/
rm -rf /opt/*
tar  -cvf /media/mmc1/home.tar /home/user/
cp -avx /home/user/* /mnt/user
rm -rf /home/user
This was the moving part.Now unmount the optfs partition and remount it to the right place
Code:
umount /mnt
mount -o rw,noatime,errors=continue,commit=1,data=writeback /dev/mmcblk0p2 /home
mount -o bind,rbind /home/opt /opt
Verify the changes
Code:
df -h
mount
Before you actually reboot, do some check, if everything works as expected.
 

The Following 2 Users Say Thank You to michaaa62 For This Useful Post:
azad1top's Avatar
Posts: 84 | Thanked: 11 times | Joined on Aug 2012 @ iran
#13
[QUOTE=michaaa62;1257090]You now should have read/write access to the data partition again, from the output, but...
Flashing is not the solution for your device!!!You have no optfs partition mounted on your device. This is critical to space on your device.

Be careful not to skip any step or to continue ignoring errors! To repair damage you do now will be more difficult to cure, but still doable.

Please try to show the partition table to verify the optfs-partition is there with the right parameters
Code:
sudo gainroot
sfdisk -l
If there is an entry in the partition table looking like this (numbers will vary!)then do
Code:
sudo gainroot
fsck -af /dev/mmcblk0p2
This will check and try to repair the
[/CODE]


Thank you so much for your tips


I'm showing the code

Code:
BusyBox v1.10.2 (Debian 3:1.10.2.legal-1osso30+0m5) built-in shell (ash) 
Enter 'help' for a list of built-in commands. 

~ $ 
~ $ 
~ $ sudo gainroot 
Root shell enabled 


BusyBox v1.10.2 (Debian 3:1.10.2.legal-1osso30+0m5) built-in shell (ash) 
Enter 'help' for a list of built-in commands. 

/home/user # sfdisk -l 

Disk /dev/mmcblk0: 982528 cylinders, 4 heads, 16 sectors/track 
Units = cylinders of 32768 bytes, blocks of 1024 bytes, counting from 0 

Device Boot Start End #cyls #blocks Id System 
/dev/mmcblk0p1 1 693760 693760 22200320 c W95 FAT32 (LBA) 
/dev/mmcblk0p2 693761 955904 262144 8388608 83 Linux 
/dev/mmcblk0p3 955905 980480 24576 786432 82 Linux swap / Solaris 
/dev/mmcblk0p4 0 - 0 0 0 Empty 

Disk /dev/mmcblk1: 121008 cylinders, 4 heads, 16 sectors/track 
Units = cylinders of 32768 bytes, blocks of 1024 bytes, counting from 0 

Device Boot Start End #cyls #blocks Id System 
/dev/mmcblk1p1 0+ 121007 121008- 3872248 b W95 FAT32 
/dev/mmcblk1p2 0 - 0 0 0 Empty 
/dev/mmcblk1p3 0 - 0 0 0 Empty 
/dev/mmcblk1p4 0 - 0 0 0 Empty 
/home/user #

But the second code it. Error will

Code:
BusyBox v1.10.2 (Debian 3:1.10.2.legal-1osso30+0m5) built-in shell (ash) 
Enter 'help' for a list of built-in commands. 

~ $ sudo gainroot 
Root shell enabled 


BusyBox v1.10.2 (Debian 3:1.10.2.legal-1osso30+0m5) built-in shell (ash) 
Enter 'help' for a list of built-in commands. 

/home/user # fsck -af /dev/mmcblk0p2
fsck 1.41.3.maemo0 (12-Oct-2008) 
/dev/mmcblk0p2: recovering journal 
fsck.ext3: unable to set superblock flags on /dev/mmcblk0p2 

/home/user #

Now what I do

Last edited by azad1top; 2012-08-29 at 13:01.
 
Posts: 2,102 | Thanked: 1,937 times | Joined on Sep 2008 @ Berlin, Germany
#14
Look bad again!
Try to get a backup of the superblock for the file system check.

Here you get the list of superblocks
Code:
sudo gainroot
dumpe2fs /dev/mmcblk0p2 | grep -i superblock
You get an output like this:
Nokia-N900:~# dumpe2fs /dev/mmcblk0p2 | grep -i superblock
dumpe2fs 1.41.3.maemo0 (12-Oct-2008)
Primary superblock at 0, Group descriptors at 1-1
Backup superblock at 32768, Group descriptors at 32769-32769
Backup superblock at 98304, Group descriptors at 98305-98305
Backup superblock at 163840, Group descriptors at 163841-163841
Backup superblock at 229376, Group descriptors at 229377-229377
Backup superblock at 294912, Group descriptors at 294913-294913
Backup superblock at 819200, Group descriptors at 819201-819201
Backup superblock at 884736, Group descriptors at 884737-884737
Backup superblock at 1605632, Group descriptors at 1605633-1605633
Then check the file system with one of the backups again like this
Code:
fsck -b 294912 -af /dev/mmcblk0p2
Hope it helps!
 

The Following User Says Thank You to michaaa62 For This Useful Post:
azad1top's Avatar
Posts: 84 | Thanked: 11 times | Joined on Aug 2012 @ iran
#15
Originally Posted by michaaa62 View Post
Look bad again!
Try to get a backup of the superblock for the file system check.

Here you get the list of superblocks
Code:
sudo gainroot
dumpe2fs /dev/mmcblk0p2 | grep -i superblock
You get an output like this:Then check the file system with one of the backups again like this
Code:
fsck -b 294912 -af /dev/mmcblk0p2
Hope it helps!
Wow just what a good help



Code:
BusyBox v1.10.2 (Debian 3:1.10.2.legal-1osso30+0m5) built-in shell (ash) 
Enter 'help' for a list of built-in commands. 

~ $ 
~ $ sudo gainroot 
Root shell enabled 


BusyBox v1.10.2 (Debian 3:1.10.2.legal-1osso30+0m5) built-in shell (ash) 
Enter 'help' for a list of built-in commands. 

/home/user # dumpe2fs /dev/mmcblk0p2 | grep -i superblock 
dumpe2fs 1.41.3.maemo0 (12-Oct-2008) 
Primary superblock at 0, Group descriptors at 1-1 
Backup superblock at 32768, Group descriptors at 32769-32769 
Backup superblock at 98304, Group descriptors at 98305-98305 
Backup superblock at 163840, Group descriptors at 163841-163841 
Backup superblock at 229376, Group descriptors at 229377-229377 
Backup superblock at 294912, Group descriptors at 294913-294913 
Backup superblock at 819200, Group descriptors at 819201-819201 
Backup superblock at 884736, Group descriptors at 884737-884737 
Backup superblock at 1605632, Group descriptors at 1605633-1605633 
/home/user # 
/home/user # 
/home/user # fsck -b 294912 -af /dev/mmcblk0p2 
fsck 1.41.3.maemo0 (12-Oct-2008) 
/dev/mmcblk0p2: ext3 recovery flag is clear, but journal has data. 
/dev/mmcblk0p2: Recovery flag not set in backup superblock, so running journal anyway. 
/dev/mmcblk0p2: recovering journal 
/dev/mmcblk0p2: ext3 recovery flag is clear, but journal has data. 
/dev/mmcblk0p2: Recovery flag not set in backup superblock, so running journal anyway. 
fsck.ext3: unable to set superblock flags on /dev/mmcblk0p2 

/home/user #

Now what I do

Last edited by azad1top; 2012-08-29 at 15:13.
 
Posts: 2,102 | Thanked: 1,937 times | Joined on Sep 2008 @ Berlin, Germany
#16
Try to check the file system with a badblocks test first then repair with more force
Code:
fsck.ext3 -c -y /dev/mmcblk0p2
fsck.ext3 -r -f -y /dev/mmcblk0p2

Last edited by michaaa62; 2012-08-29 at 15:14. Reason: Added option -y to speed things up.
 

The Following User Says Thank You to michaaa62 For This Useful Post:
azad1top's Avatar
Posts: 84 | Thanked: 11 times | Joined on Aug 2012 @ iran
#17
Originally Posted by michaaa62 View Post
Try to check the file system with a badblocks test first then repair with more force
Code:
fsck.ext3 -c -y /dev/mmcblk0p2
fsck.ext3 -r -f -y /dev/mmcblk0p2



Open the code displayed::




Code:
BusyBox v1.10.2 (Debian 3:1.10.2.legal-1osso30+0m5) built-in shell (ash) 
Enter 'help' for a list of built-in commands. 

~ $ sudo gainroot 
Root shell enabled 


BusyBox v1.10.2 (Debian 3:1.10.2.legal-1osso30+0m5) built-in shell (ash) 
Enter 'help' for a list of built-in commands. 

/home/user # fsck.ext3 -c -y /dev/mmcblk0p2 
e2fsck 1.41.3.maemo0 (12-Oct-2008) 
/dev/mmcblk0p2: recovering journal 
fsck.ext3: unable to set superblock flags on /dev/mmcblk0p2 

/home/user # fsck.ext3 -r -f /dev/mmcblk0p 
e2fsck 1.41.3.maemo0 (12-Oct-2008) 
fsck.ext3: No such file or directory while trying to open /dev/mmcblk0p 

The superblock could not be read or does not describe a correct ext2 
filesystem. If the device is valid and it really contains an ext2 
filesystem (and not swap or ufs or something else), then the superblock 
is corrupt, and you might try running e2fsck with an alternate superblock: 
e2fsck -b 8193 <device> 

/home/user #

Thank you so much it works well Mydd


Now what I do. !!!!


I'm not good at English sorry if I misspelled my time because I'm in Persian
 
Posts: 2,102 | Thanked: 1,937 times | Joined on Sep 2008 @ Berlin, Germany
#18
/home/user # fsck.ext3 -r -f /dev/mmcblk0p
There is a typo in the last command, that is why the error message is different i am afraid. Useless to try again anyway There is no file system check possible, that looks bad, familiar and bad.
Nevertheless try to mount the partition
Code:
sudo gainroot
mount /dev/mmcblk0p2 /mnt
Lets hope it works
 

The Following User Says Thank You to michaaa62 For This Useful Post:
azad1top's Avatar
Posts: 84 | Thanked: 11 times | Joined on Aug 2012 @ iran
#19
Originally Posted by michaaa62 View Post
There is a typo in the last command, that is why the error message is different i am afraid. Useless to try again anyway There is no file system check possible, that looks bad, familiar and bad.
Nevertheless try to mount the partition
Code:
sudo gainroot
mount /dev/mmcblk0p2 /mnt
Lets hope it works
I wanna apologize for the spelling errors. : D

The error message is different. I'll order a copy., But the code

But that is where it gets difficult, I


Code:
BusyBox v1.10.2 (Debian 3:1.10.2.legal-1osso30+0m5) built-in shell (ash) 
Enter 'help' for a list of built-in commands. 

~ $ sudo gainroot 
Root shell enabled 


BusyBox v1.10.2 (Debian 3:1.10.2.legal-1osso30+0m5) built-in shell (ash) 
Enter 'help' for a list of built-in commands. 

/home/user # mount /dev/mmcblk0p2 /mnt 
mount: mounting /dev/mmcblk0p2 on /mnt failed: Invalid argument 
/home/user # 


Now
 
azad1top's Avatar
Posts: 84 | Thanked: 11 times | Joined on Aug 2012 @ iran
#20


Last edited by azad1top; 2012-08-30 at 12:25.
 
Reply


 
Forum Jump


All times are GMT. The time now is 19:04.