Reply
Thread Tools
Posts: 16 | Thanked: 11 times | Joined on Oct 2011
#1
The phone periodically restarts itself after a reboot is loaded only the second time. In the first boot it hangs after the splash NOKIA.

In the logs found this - /var/log/maemo-optify-boottime.log
2012-03-25 16:04:47 :: not enough free space in /home (need at least 200 MB free), quitting.
initctl: MOUNTS_OK event failed
2012-03-25 16:06:24 :: not enough free space in /home (need at least 200 MB free), quitting.
1+0 records in
1+0 records out
512 bytes (512B) copied, 1.222565 seconds, 418B/s
As can be seen for the first time the phone for some reason can not mount a directory
Free space:
Nokia-N900:~# df -h
Filesystem Size Used Available Use% Mounted on
rootfs 227.9M 182.7M 41.0M 82% /
ubi0:rootfs 227.9M 182.7M 41.0M 82% /
tmpfs 1.0M 72.0K 952.0K 7% /tmp
tmpfs 256.0K 92.0K 164.0K 36% /var/run
none 10.0M 72.0K 9.9M 1% /dev
tmpfs 64.0M 4.0K 64.0M 0% /dev/shm
/dev/mmcblk0p2 2.0G 1.6G 310.7M 84% /home
/home/opt 2.0G 1.6G 310.7M 84% /opt
/opt/pymaemo/usr/lib/python2.5 2.0G 1.6G 310.7M 84% /usr/lib/python2.5
/opt/pymaemo/usr/share/pyshared 2.0G 1.6G 310.7M 84% /usr/share/pyshared
/opt/pymaemo/usr/lib/pyshared 2.0G 1.6G 310.7M 84% /usr/lib/pyshared
/opt/pymaemo/usr/share/python-support 2.0G 1.6G 310.7M 84% /usr/share/python-support
/opt/pymaemo/usr/lib/python-support 2.0G 1.6G 310.7M 84% /usr/lib/python-support
/dev/mmcblk0p1 27.0G 23.9G 3.1G 89% /home/user/MyDocs
I would be grateful for any ideas how to fix this

Last edited by SeT; 2012-03-25 at 12:23.
 
ibrakalifa's Avatar
Posts: 1,411 | Thanked: 786 times | Joined on Dec 2011 @ Harmattan
#2
flash it with custom emmc, maybe,
__________________
~$
~#
 
Posts: 16 | Thanked: 11 times | Joined on Oct 2011
#3
Originally Posted by ibrakalifa View Post
flash it with custom emmc, maybe,
This is an last, not the best option =)
 
Posts: 181 | Thanked: 79 times | Joined on Jan 2010
#4
I do not have the constantly restarting problems, but I have the same log file growing since my phone restarted itself once. It never happened again (the restarting), but the file /var/log/maemo-optify-boottime.log is adding a new record every boot:
2012-10-25 18:01:20 :: not enough free space in /home (need at least 200 MB free), quitting.
1+0 records in
1+0 records out
512 bytes (512B) copied, 1.222565 seconds, 418B/s

Any idea about which process is writting to that file in every boot of the phone?
Thanks.
 
Posts: 181 | Thanked: 79 times | Joined on Jan 2010
#5
Well, I have made some progress, but still need an expert help.

The script which is generating the log is /usr/sbin/maemo-optify-auto-opt.sh, which calls the function dfree inside /usr/sbin/maemo-optify-lib.sh. dfree function is as follows

Code:
dfree()  
 {  
   space=`/bin/busybox stat -ft /home | /bin/busybox awk '{print int($5*$9/(1024*1024)) }'`  
   [ $? -ne 0 ] && return 0  
   return $space  
 }
If you execute the command
Code:
stat -ft /home | awk '{print int($5*$9/(1024*1024)) }'
you get two integers, not only one, and the last one is 0. Indeed, I have made an script to see the value of the returned $space variable, and it is 0!!! I cannot understand why it happens only in the last days (maybe a change in the busybox stat command?) Any idea?

On the other hand, I do not know where the /usr/sbin/maemo-optify-auto-opt.sh is called from on every reboot.

Please, help.

Thanks a lot.

Last edited by ikerrg; 2012-11-07 at 19:22.
 
Posts: 1,468 | Thanked: 2,703 times | Joined on Feb 2011 @ Germany
#6
@ikerrg,

Very interesting analysis. I don't have /usr/sbin/maemo-optify-auto.sh (but I may have removed many Nokia packages). Could you please do "dpkg -S /usr/sbin/maemo-optify-auto.sh" to see from which package this thing is coming?

Furthermore, that way of checking space using stat seems quite broken.

$5 is the block size, but
$9 is the total number of inodes

so the dfree() function is mixing apples with bananas

It should either use df[*] or replace $9 with $8, which is the number "available blocks" ($9 is the number of "free blocks", don't know what the difference may be).

Plus I don't know why awk returns two values when multiplying. Seems that busybox is way beyond broken (I tested with latest busybox-power).
[*]
Code:
dfree()  
 {  
   space=`df -B 1 | tail -1 | awk '{ print $4 }' `  
   [ $? -ne 0 ] && return 0  
   return $space  
 }
Good luck.

PS: I do have (in my most "normal" N900) a /var/log/maemo-optify-boottime.log, last modified about 8 months ago. Nothing in the boot process seems to be touching it, so it must have come from some package that I have uninstalled.
 
Posts: 181 | Thanked: 79 times | Joined on Jan 2010
#7
Thanks reinob. You are always there!!

I have moved the question to a more specific new thread and I give you more details on it: http://talk.maemo.org/showthread.php?t=87765

Let's continue there!
 
Reply

Thread Tools

 
Forum Jump


All times are GMT. The time now is 06:35.