Closed Bug 906609 Opened 11 years ago Closed 11 years ago

[B2G][Helix][Boot][HanCheng]Device block at boot logo when the data partition has only 4KB space left.

Categories

(Firefox OS Graveyard :: Vendcom, defect, P3)

defect

Tracking

(blocking-b2g:-)

RESOLVED INVALID
blocking-b2g -

People

(Reporter: lecky.wanglei, Unassigned)

References

Details

(Whiteboard: [POVB])

Attachments

(7 files)

User Agent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.1; Trident/4.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; aff-kingsoft-ciba; .NET4.0C; .NET4.0E)

Steps to reproduce:

1. Fill the user data partition(/data) untill it remains 4KB.
2. Reboot the device.


Actual results:

2. The device some times block an the "based on mozilla technology" logo. Probability of failure is about 1/20. Once it is blocked, it can't boot normally untill I delete some files.


Expected results:

2. The device should boot normally.

[Question]
1. How much space does the B2G need in data partition to boot normally?
2. Does B2G do something to protect the space left? e.g. If the device have only 10MB space left, B2G will not allow the user to install apps.
Priority: -- → P2
Summary: [B2G][Helix][Boot][HanCheng] → [B2G][Helix][Boot][HanCheng]Device block at boot logo when the data partition has only 4KB space left.
4 KB left isn't possible to get down to unless a rooted user pushes enough data into /data to get to that level. You need to see if you can reproduce this from a user workflow, which requires testing if you can still boot at 5 MB left.
Hi Jason,

Thanks!

Why can't user get down to 4 KB left? If the user install more enough apps, when will the B2G OS prevent the user from installing mor apps?

If there is only 5 MB left, then the user receive some emails or messages, or save some other user info, I think the device can get down to less space. Does the B2G have any machanism to prevent this?
(In reply to lecky from comment #2)
> Hi Jason,
> 
> Thanks!
> 
> Why can't user get down to 4 KB left? If the user install more enough apps,
> when will the B2G OS prevent the user from installing mor apps?
> 
> If there is only 5 MB left, then the user receive some emails or messages,
> or save some other user info, I think the device can get down to less space.
> Does the B2G have any machanism to prevent this?

When 5 MB left of internal storage in /data is hit. At that point, the user is presented with a toast indicating that there's only 5 MB left of storage. Additionally, a persistent notification is present indicating that storage is low along with how much. When 10 MB is hit again, the persistent notification disappears.
Attached image 2013-08-21-11-44-39.png
(In reply to Jason Smith [:jsmith] from comment #3)
> When 5 MB left of internal
> storage in /data is hit. At that point, the user is presented with a toast
> indicating that there's only 5 MB left of storage. Additionally, a
> persistent notification is present indicating that storage is low along with
> how much. When 10 MB is hit again, the persistent notification disappears.

My device get down to 4.4 MB left now. Please refer to the attached 2013-08-21-11-44-39.png. But there isn't a toast indicating or persistent notification.
Attached image 1980-01-06-07-07-42.png
Hi Jason,

I can still install apps. Now the available space is 3.9 MB. But there isn't any notification. Please refer to 1980-01-06-07-07-42.png.
Hi Jason,

Where can I see the persistent notification?
See Also: → low-storage
Hi, how do you check the available space?
Hi,

I check it in Settings->Application storage.
Please check the back ground of attached images.
Hi,
For the system doesn't show any notification or prevent user from increase application storage when the device reach 5M left, this issue become more important.
Priority: P2 → P1
(In reply to lecky from comment #10)
> Hi,
> For the system doesn't show any notification or prevent user from increase
> application storage when the device reach 5M left, this issue become more
> important.

Which device are you using for testing this?

Note that you need to have fanotify kernel support in order to get low device storage notifications and locks. Check bug 861921 and bug 853350 for extra information about this.
Flags: needinfo?(lecky.wanglei)
Blocks: low-storage
See Also: low-storage
blocking-b2g: --- → hd?
Flags: needinfo?(lecky.wanglei)
Hi,

I use hd1.1 version in my device.

I checked the patches in the bug 861921 and bug 853350.
In our code, we do have the gecko and gaia "Device storage watcher" patches attached in this two bugs.
Flags: needinfo?(ferjmoreno)
Hi,

I can't find the definition of "disk_space_watcher.low_threshold" in hd1.1 code. Maybe I need to define it in /gecko/b2g/app/b2g.js?
(In reply to lecky from comment #13)
> Hi,

I can't find the definition of "disk_space_watcher.low_threshold" in
> hd1.1 code. Maybe I need to define it in /gecko/b2g/app/b2g.js?

Eh...I found it.

GonkDiskSpaceWatcher::GonkDiskSpaceWatcher() :

  mLowThreshold = Preferences::GetInt(WATCHER_PREF_LOW, 5) * 1024 * 1024;
(In reply to lecky from comment #12)
> Hi,
> 
> I use hd1.1 version in my device.
> 
> I checked the patches in the bug 861921 and bug 853350.
> In our code, we do have the gecko and gaia "Device storage watcher" patches
> attached in this two bugs.

I am not asking for Gecko/Gaia versions but for the device you are testing on :)

In order to make the GonkDiskSpaceWatcher to work the your device needs to have fanotify kernel support. That's independent from Gecko and Gaia. To easily check if your device has no fanotify support you can search in your logcat output for a message like: "Warning: No fanotify support on this device's kernel."
Flags: needinfo?(ferjmoreno)
Hi,

I'm testing on a helix phone.

The device has only 3.9M left. I can't find the "Warning: No fanotify support on this device's kernel." in logcat.
Weird.

Unfortunately, I have no helix phone to test :(.

Could you manually check if you have fanotify kernel support? I think you can do that checking fs/notify/fanotify/Kconfig  and fs/notify/Kconfig.

Also, could you attach a full logcat output, please?
Flags: needinfo?(lecky.wanglei)
Looks like Helix isn't getting the 5 MB warning - see https://bugzilla.mozilla.org/show_bug.cgi?id=907601#c9 that shows a second confirmation.

Per comment 17 - this is likely POVB with Helix needing to have fanotify kernel support.
(In reply to Jason Smith [:jsmith] from comment #18)
> Looks like Helix isn't getting the 5 MB warning - see
> https://bugzilla.mozilla.org/show_bug.cgi?id=907601#c9 that shows a second
> confirmation.

>Per comment 17 - this is likely POVB with Helix needing to
> have fanotify kernel support.

It's a little diffrent from bug 907601.
In this bug, we use /data.
In bug 907601, the camera use /sdcard.
Flags: needinfo?(lecky.wanglei)
(In reply to Fernando Jiménez Moreno [:ferjm] (needinfo, please) from comment #17)

>Could you manually check if you have fanotify kernel support? I think you can do that checking
> fs/notify/fanotify/Kconfig  and fs/notify/Kconfig.

Please see the fanotify in my kernel. Do I need to change the config from "n" to "y"?

B2G/kernel/fs/notify/fanotify/Kconfig:
config FANOTIFY
        bool "Filesystem wide access notification"
        select FSNOTIFY
        select ANON_INODES
        default n

config FANOTIFY_ACCESS_PERMISSIONS
        bool "fanotify permissions checking"
        depends on FANOTIFY
        depends on SECURITY
        default n

B2G/kernel/fs/notify/Kconfig:
config FSNOTIFY
        def_bool n


>Also, could you attach a full logcat output, please?

OK, Please check the attached DiskSpace-08-29-11-35.log.
(In reply to lecky from comment #21)
> (In reply to Fernando Jiménez Moreno [:ferjm] (needinfo, please) from
> comment #17)
> 
> >Could you manually check if you have fanotify kernel support? I think you can do that checking
> > fs/notify/fanotify/Kconfig  and fs/notify/Kconfig.
> 
> Please see the fanotify in my kernel. Do I need to change the config from
> "n" to "y"?
> 

Yes, please :)

> B2G/kernel/fs/notify/fanotify/Kconfig:
> config FANOTIFY
>         bool "Filesystem wide access notification"
>         select FSNOTIFY
>         select ANON_INODES
>         default n

Here: "default y"

> 
> config FANOTIFY_ACCESS_PERMISSIONS
>         bool "fanotify permissions checking"
>         depends on FANOTIFY
>         depends on SECURITY
>         default n
> 
> B2G/kernel/fs/notify/Kconfig:
> config FSNOTIFY
>         def_bool n
> 

And here: "def_bool y"


> >Also, could you attach a full logcat output, please?
> 
> OK, Please check the attached DiskSpace-08-29-11-35.log.

I was expecting a full log after rebooting the device. Sorry for not being more clear about this. The warning about fanotify not supported should appear during the boot process, not after the device enters in the low storage situation, so it should be one of the first log messages. According to your kernel configuration, you should be seeing the warning. If not, there might be a bug in Gecko. It would be great if you could confirm that you see this warning in the full logcat.
Attached file log-09-03-10-49.txt
Hi Fernando,

Sorry to reply late. I do the changes you told me. But there still isn't any notification.

My step:
1. Change the fanotify config in kernel as you told me.
2. Flash the phone, and fill the /date to 4 MB left.
3. Reboot the phone, and get the logcat.

Please help check log-09-03-10-49.txt. There hasn't the massage "Warning: No fanotify support on this device's kernel."
gaia:      134356dc21d0627455f8bc536b140a18f39e20e9
gecko:     2e2b4393b0581ef72a1cb70fc5f002cd82a9302a
gonk-misc: ca9192d7ef6037016d4723647d86b72f7a410633
Hi Viral,
As fernando does not have a device, please help from Taipei on this together with Fernando.
Flags: needinfo?(vwang)
Hi Wayne,

Shall we have updated kernel which enable those config from Fernand's suggestion?
GonkDiskSpaceWatcher need to work base on fanotify kernel support.
Flags: needinfo?(vwang)
Hi Lecky,

could you please provide the .config under your kernel directory?
Thank you.
Flags: needinfo?(lecky.wanglei)
Hi Viral,

Maybe there is something wrong with my kenel build. Although I changed the config in FANOTIFY and FSNOTIFY in Kconfig, the .config didn't change. The CONFIG_FSNOTIFY is always y, and the CONFIG_FANOTIFY is always n.
Flags: needinfo?(lecky.wanglei)
Attached file log-09-06-10-58.txt
Hi,

Finally I enabled the fanotify in kernel, and the "Device space low. Less than 2 MB remaining" came out in system notification. But I still can install apps from Marketplace.

Please help check the attached log file log-09-06-10-58.txt. I installed "Pasjans", "YOUZEEK", and "SoundCloud" after the disk space has only 2 MB left.
Flags: needinfo?(vwang)
I didn't see following config is enable, could you please help to check it again?
> config FANOTIFY_ACCESS_PERMISSIONS
>         bool "fanotify permissions checking"
>         depends on FANOTIFY
>         depends on SECURITY
>         default n

I also check the device in my hand (of source we didn't have updated kernel with fanotify enable). It shows the warning log mention in bugzilla. I think you should see the same log if there's any missing about fanotify config.

01-13 09:56:09.380 I/Gecko   (  158): Warning: No fanotify support in this device's kernel.

Could you please shared your updated kernel for us to check if we can reproduce in our side for more detail information? thanks.
Flags: needinfo?(vwang) → needinfo?(lecky.wanglei)
Jason, Fernando,

Do you know if when the low memory warning pops, the user is prevented from installing any more applications or if it's simply a persistent warning which does not impose any functional restriction?

(In reply to lecky from comment #30)

> Finally I enabled the fanotify in kernel, and the "Device space low. Less
> than 2 MB remaining" came out in system notification. But I still can
> install apps from Marketplace.
Flags: needinfo?(jsmith)
Flags: needinfo?(ferjmoreno)
Yes, we prevent apps to be downloaded and installed if the device is running low in storage. In this case, the user gets an additional prompt if storage space check fails during app install.

Check bug 809948 and bug 818848.

Note that checking for device storage during app download/installation is independent from the DiskSpaceWatcher component mentioned in this bug and so it is not dependent of fanotify support. (At least until bug 863596 is done). If you are able to install an app that leaves the device with less than 5Mb [1] of free storage, then there might be a bug.

I am leaving the ni? open so I can check that this is working with Mozilla builds.

[1] https://mxr.mozilla.org/mozilla-central/source/dom/apps/src/AppDownloadManager.jsm#22
(In reply to Wayne Chang [:wchang] from comment #32)
> Jason, Fernando,
> 
> Do you know if when the low memory warning pops, the user is prevented from
> installing any more applications or if it's simply a persistent warning
> which does not impose any functional restriction?
> 
> (In reply to lecky from comment #30)
> 
> > Finally I enabled the fanotify in kernel, and the "Device space low. Less
> > than 2 MB remaining" came out in system notification. But I still can
> > install apps from Marketplace.

What ferjm said pretty much. If you hit the low space 5 MB threshold, then you shouldn't be able to install apps. I'll put qawanted here to check if we're failing to install apps when the low space threshold is hit.
Flags: needinfo?(jsmith)
Keywords: qawanted
(In reply to viral [:viralwang] from comment #31)
> I didn't see following config is enable, could you please help to check it
> again?
> config FANOTIFY_ACCESS_PERMISSIONS
>         bool "fanotify
> permissions checking"
>         depends on FANOTIFY
>         depends on
> SECURITY
>         default n

Must I enable FANOTIFY_ACCESS_PERMISSIONS? Fernando didn't say need to enable it in Comment 23.

No I can see the system notification of "Device space low". But I still can install apps.
Flags: needinfo?(lecky.wanglei)
William can you help with the qawanted here, find out if apps can be installed after the notification pops.

Fernando, if there is a bug (that apps can still be installed when low disk space), would you be the right person to check?

Koi? according to comment 33 and comment 35
blocking-b2g: hd? → koi?
Flags: needinfo?(whsu)
(In reply to Wayne Chang [:wchang] from comment #36)
> William can you help with the qawanted here, find out if apps can be
> installed after the notification pops.
> 
> Fernando, if there is a bug (that apps can still be installed when low disk
> space), would you be the right person to check?
> 
> Koi? according to comment 33 and comment 35

Note - for qawanted, you'll want to test this on Helix and Leo as a point of comparison. If the bug only happens on Helix, then this is POVB.
Hi, Wayne and Jason,

Could I say "NO"!?......Just kidding!
----------------------------------------------------------------------------
As I tested in Helix device (V1.1.0 hd), I can see the warning message.
In the meanwhile, the packaged app cannot be installed but hosted app can be installed.
If the app cannot be installed, the system pops up a toast/message - "...FORBIDDEN". 
As attachment.

* Test Build: (Mozilla - V1.1.0 hd)
 - Gaia:     75228cd1223c22642623e99c37f7bc8b2a355d86
 - Gecko:    http://hg.mozilla.org/releases/mozilla-b2g18_v1_1_0_hd/rev/4b09975b2d7c
 - BuildID   20130909042204
 - Version   18.0

By the way, I don't test Leo device since it work on Helix device.

Hope these information are sufficient.
If you still need my help, please feel free to contact me.
Have a nice Biz trip!

--------- Marked it as "WORKSFORME" ---------
Status: UNCONFIRMED → RESOLVED
Closed: 11 years ago
Flags: needinfo?(whsu)
Resolution: --- → WORKSFORME
Attached image Full App Storage
Flags: needinfo?(ferjmoreno)
I'm confused - comment 38 implies that we aren't blocking hosted app installation on low storage. Can you file a separate bug for this in core --> dom: apps?

I don't think the qawanted testing concludes this is workss for me either - a works for me would imply that trying to write appcache resources or any type of storage in general when the low storage threshold is hit would fail. The above discussion implies that fanotify might have not been enabled.
Status: RESOLVED → REOPENED
Ever confirmed: true
Resolution: WORKSFORME → ---
Component: Gaia::System → Vendcom
Keywords: qawanted
Whiteboard: [POVB]
We have not hooked up fanotify to the webapps code yet. We are using polling for package downloads, but we don't check for hosted apps.
Fabrice,

Should we be concerned if hosted apps are still installable?

How likely are users to be impacted by installing more hosted apps?
Flags: needinfo?(fabrice)
(In reply to Wayne Chang [:wchang] from comment #42)
> Fabrice,
> 
> Should we be concerned if hosted apps are still installable?
> 
> How likely are users to be impacted by installing more hosted apps?

Hosted apps with no appcache (which are the ones affected, not hosted apps w/appcache) consume very little space overall. Even though this does violate the 5 MB threshold rule, it's not a severe issue if hosted apps w/o appcache can still be installed. It's a valid bug though.
I agree with Jasons. We'll fix that, but won't block.
Flags: needinfo?(fabrice)
Hi Fernando,

After I enable fanotify in kernel, there is an error in Gecko.
"01-11 14:03:19.569: INFO/Gecko(164): About to crash: fanotify_event_metadata read error."
Flags: needinfo?(ferjmoreno)
The phone block at "Application storage" screen in settings. B2G does not reboot.

root@android:/ # b2g-ps
b2g-ps
APPLICATION      USER     PID   PPID  VSIZE  RSS     WCHAN    PC         NAME
b2g              root      164   1     0      0     ffffffff 00000000 Z b2g
Homescreen       app_395   395   164   81540  18896 ffffffff 40038630 S /system/b2g/plugin-container
Settings         app_505   505   164   145696 23172 ffffffff 400d7a10 S /system/b2g/plugin-container
(Preallocated a  root      951   164   65384  9672  ffffffff 400e4630 S /system/b2g/plugin-container
Hi Wayne :
 Please help us to push to merge this case into V1.1 HD. It blocked the Helix Device .If you can not resolve it , please get the authorization from carrier.
(In reply to Fabrice Desré [:fabrice] from comment #44)
> I agree with Jasons. We'll fix that, but won't block.

This is bug 863596
Flags: needinfo?(ferjmoreno)
(In reply to lecky from comment #46)
> Hi Fernando,
> 
> After I enable fanotify in kernel, there is an error in Gecko.
> "01-11 14:03:19.569: INFO/Gecko(164): About to crash:
> fanotify_event_metadata read error."

Have you got the fix for bug 874148 applied in your build?
Sorry for the late reply.
I submitted a bug for a legacy problem (5 MB threshold).
Bug 917249.
(In reply to Fernando Jiménez Moreno [:ferjm] (needinfo, please) from comment #50)
> Have you got the fix for bug 874148 applied in your build?

Yes, I have got it. 
I found it only crash in eng build, but not in user build. Is there anythind diffrent between eng build and user build for DiskSpaceWatcher?
Flags: needinfo?(ferjmoreno)
See Also: → 917249
(In reply to lecky from comment #52)
> (In reply to Fernando Jiménez Moreno [:ferjm] (needinfo, please) from
> comment #50)
> > Have you got the fix for bug 874148 applied in your build?
> 
> Yes, I have got it. 
> I found it only crash in eng build, but not in user build. Is there anythind
> diffrent between eng build and user build for DiskSpaceWatcher?

I cannot think about any reason why it may fail in an eng build. Fabrice, any idea?
Flags: needinfo?(ferjmoreno) → needinfo?(fabrice)
No idea either. We don't do anything special with the DiskSpaceWatcher on eng vs user builds.
Flags: needinfo?(fabrice)
Hi Fernando,

I found there is an error with webapps in kernel(/data/local/webapps/wikipedia/cache/WikipediaMobileFirefoxOS/messages). User build doesn't have this dir, so this is not happen in user build.
I've no idea how does Gecko call the __ext4_check_dir_entry in kernel, do you have any suggestion?

01-06 04:30:08 <3>[659, DeviceS~che I/O] [   75.950033] __ext4_check_dir_entry : rlen is : 8 
01-06 04:30:08 <2>[659, DeviceS~che I/O] [   75.952488] EXT4-fs error (device mmcblk0p18): ext4_readdir:217: inode #338: block 24855: comm DeviceS~che I/O: path /data/local/webapps/wikipedia/cache/WikipediaMobileFirefoxOS/messages: bad entry in directory: rec_len is smaller than minimal - offset=4088(4088), inode=0, rec_len=8, name_len=0
01-06 04:30:08 <4>[659, DeviceS~che I/O] [   75.952534] 
01-06 04:30:08 <4>[659, DeviceS~che I/O] [   75.952541] ext4_handle_kmsg is called
01-06 04:30:08 <4>[659, DeviceS~che I/O] [   75.952553] 
01-06 04:30:08 <4>[659, DeviceS~che I/O] [   75.952559] ext4_kmsg_flag is equal to : 0
01-06 04:30:08 <4>[659, DeviceS~che I/O] [   75.952768] 
01-06 04:30:08 <4>[659, DeviceS~che I/O] [   75.952776] fdMounts is equal to : 177
01-06 04:30:08 <4>[659, DeviceS~che I/O] [   75.954213] 
01-06 04:30:08 <4>[659, DeviceS~che I/O] [   75.954221] Internal SD card block name is : /dev/block/vold/179:19
01-06 04:30:08 <4>[659, DeviceS~che I/O] [   75.954234] 
01-06 04:30:08 <4>[659, DeviceS~che I/O] [   75.954239] Internal SD card is mounted on : /mnt/sdcard
01-06 04:30:08 <4>[659, DeviceS~che I/O] [   75.956739] 
01-06 04:30:08 <4>[659, DeviceS~che I/O] [   75.956754] The log path is : /mnt/sdcard/ext4_error_log01-06 04:30:08 <3>[659, DeviceS~che I/O] [   75.966913] Aborting journal on device mmcblk0p18-8.
01-06 04:30:08 <2>[659, DeviceS~che I/O] [   75.969984] EXT4-fs (mmcblk0p18): Remounting filesystem read-only
Flags: needinfo?(ferjmoreno)
Hi Wayne ,could we set some alert for the end user to know about the low of memory?
Flags: needinfo?(wchang)
Hi Lecky,

There is already notification as shown in attachment 803066 [details] when the storage is low. What other alert do you wish to show?
Flags: needinfo?(wchang)
(In reply to lecky from comment #55)
> Hi Fernando,
> 
> I found there is an error with webapps in
> kernel(/data/local/webapps/wikipedia/cache/WikipediaMobileFirefoxOS/
> messages). User build doesn't have this dir, so this is not happen in user
> build.
> I've no idea how does Gecko call the __ext4_check_dir_entry in kernel, do
> you have any suggestion?

Sorry, I have no idea either. Do you think that's causing the crash you mentioned in comment 46. FWIW I don't think Gecko calls directly __ext4_check_dir_entry. In any case, Dave might know.
Flags: needinfo?(ferjmoreno) → needinfo?(dhylands)
the /data/local/webapps/wikipedia/cache path is used to preload the offline cache, so something deep in the file access stack is ending up calling __ext4_check_dir_entry. In user builds it will be under /system/b2g/webapps/wikipedia/cache if wikipedia is preloaded.

Also, is this reproducible on other devices or only helix? If not this may be a fs bug specific to the helix kernel?
Triage: minus. given that user build is working fine and this is not likely an end user scenario that an end user can get to 4KB. IIRC, We have mechanisms to restrict write access when we are down to a certain amount of storage left which is far greater than 4KB.
blocking-b2g: koi? → -
(In reply to Fabrice Desré [:fabrice] from comment #59)
> the /data/local/webapps/wikipedia/cache path is used to preload the offline
> cache, so something deep in the file access stack is ending up calling
> __ext4_check_dir_entry. In user builds it will be under
> /system/b2g/webapps/wikipedia/cache if wikipedia is preloaded.
> 
> Also, is this reproducible on other devices or only helix? If not this may
> be a fs bug specific to the helix kernel?

__ext4_check_dir_entry gets called through ext4_readdir, which is called through readdir when reading from an ext4 filesystem.

readdir is called from many places within gecko.
Flags: needinfo?(dhylands)
Priority: P1 → P3
(In reply to Dave Hylands [:dhylands] (on PTO back Oct 15) from comment #61)
>__ext4_check_dir_entry gets called
> through ext4_readdir, which is called through readdir when reading from an
> ext4 filesystem.

>readdir is called from many places within gecko.

Does the read(aFd, buf, sizeof(buf)) in OnFileCanReadWithoutBlocking(GonkDiskSpaceWatcher.cpp) will call ext4_readdir? I found the errno after call read is EROFS(Read-only file system).
So I think the crash issue must be caused by the error in Comment 55.

There are too many files in /data/local/webapps/wikipadia/cache. Maybe the buf[4096] in OnFileCanReadWithoutBlocking is too small?
Flags: needinfo?(ferjmoreno)
Flags: needinfo?(dhylands)
I found there is something wrong with the path /data/local/webapps/wikipadia/cache/WikipediaMobileFirefoxOS/messages. When I enter this path and list all the files under this path, than kernel will occur the issue in Comment 55, whatever I have defined CONFIG_FANOTIFY or not.

So, could someone help check what's the problem with this path? I think you can also reproduce it on helix phone.
(In reply to lecky from comment #62)
> (In reply to Dave Hylands [:dhylands] (on PTO back Oct 15) from comment #61)
> >__ext4_check_dir_entry gets called
> > through ext4_readdir, which is called through readdir when reading from an
> > ext4 filesystem.
> 
> >readdir is called from many places within gecko.
> 
> Does the read(aFd, buf, sizeof(buf)) in
> OnFileCanReadWithoutBlocking(GonkDiskSpaceWatcher.cpp) will call
> ext4_readdir? I found the errno after call read is EROFS(Read-only file
> system).
> So I think the crash issue must be caused by the error in Comment 55.

Not directly. The read is reading notification events, which may have been posted as part of somebody else doing a readdir.

> There are too many files in /data/local/webapps/wikipadia/cache. Maybe the
> buf[4096] in OnFileCanReadWithoutBlocking is too small?

I'm not sure how those 2 things are related to each other?
Flags: needinfo?(dhylands)
(In reply to lecky from comment #63)
> I found there is something wrong with the path
> /data/local/webapps/wikipadia/cache/WikipediaMobileFirefoxOS/messages. When
> I enter this path and list all the files under this path, than kernel will
> occur the issue in Comment 55, whatever I have defined CONFIG_FANOTIFY or
> not.
> 
> So, could someone help check what's the problem with this path? I think you
> can also reproduce it on helix phone.

So, it sounds to me like there is some corruption in the filesystem.

Which version of FxOS are you running?

I was using master, and installed the Wikipedia app from marketplace. It created /data/local/webapps/{f3dc1667-9484-41aa-a12e-98155ffa920c} and not /data/local/webapps/wikipedia
Hi Dave,

Thanks very much for your reply. I get it.
For this issue is not about DiskSpaceWatcher, I will close this bug. 
I have found a Bug 925617 for the readdir error, Please help analyze.

I am using Helix phone, with V1.1.0 hd. Our wikipedia was preinstalled.
Status: REOPENED → RESOLVED
Closed: 11 years ago11 years ago
Resolution: --- → INVALID
Flags: needinfo?(ferjmoreno)
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: