-
-
Notifications
You must be signed in to change notification settings - Fork 319
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fsSize
returns empty array on some devices
#885
Comments
@MauriceNino thank you! Will try to work on it this weekend. So basically, instead of returning what you provided in the example, we just get an empty array? |
@MauriceNino ... as your command getting the underlying information from the OS is different to what I am using in the library ... can you make sure to retrieve the following info an from the target machine:
Thank you in advance. |
Thank you for looking into this! As far as I know some flag of those is not working in alpine linux. I think it was the @SecOps-7 can you please test this by executing the command as well?
and also try the following because I don't know if the above one works without a shell:
|
I have executed the command on my container - can only provide a screenshot as I am on my phone right now, but I expect this to happen for the other users as well: But for clarification, |
@MauriceNino I am a little confused ....
I just need to exactly know the environment to be able to reproduce the issue. Can you provide more details about the environment? If it is a docker container, it would also be interesting to know things like volume shares, ... Thank you in advance. |
@sebhildebrandt Sorry I could have worded this better. What I meant is that all the users who have had problems with this, had Ubuntu 22 or 23 as a host, but all had the alpine docker container running that my application is running in. Unfortunately I don't know what volume shares are, but maybe @SecOps-7 can answer that question? |
Morning, I ran the requested commands, I get the following output.
|
@SecOps-7 thank you for running the commands, unfortunately I messed one up. Can you please run this one again?
|
I don't have any volumes shared on the Ubuntu host itself. I do however have all my NAS Media folders mounted via cifs.
|
@MauriceNino seems df does not accept the -l or -x operators... I got the below errors and then was able to run it successfully after removing l and x.
|
The command executes fine with the all the operators on my local Ubuntu.
|
Yeah, that should be fine - that's what the fallback is for, right @sebhildebrandt ? |
@MauriceNino right, but inside a container I get just the result inside of the container (basically the isolated environment containers are made for) and not the result of the host machine, right? |
@sebhildebrandt Yes, but with my application, I instruct my users to mount the entire host path into the container at For example, here is the output of const sizes = [
{
fs: 'overlay',
type: 'overlay',
size: 105089261568,
used: 41191706624,
available: 58512068608,
use: 41.31,
mount: '/',
rw: false
},
{
fs: '/dev/mapper/ubuntu--vg-ubuntu--lv',
type: 'ext4',
size: 105089261568,
used: 41191706624,
available: 58512068608,
use: 41.31,
mount: '/mnt/host',
rw: true
},
{
fs: 'efivarfs',
type: 'efivarfs',
size: 196608,
used: 92160,
available: 99328,
use: 48.13,
mount: '/mnt/host/sys/firmware/efi/efivars',
rw: false
},
{
fs: '/dev/nvme0n1p2',
type: 'ext4',
size: 2040373248,
used: 284254208,
available: 1631969280,
use: 14.83,
mount: '/mnt/host/boot',
rw: false
},
{
fs: '/dev/nvme0n1p1',
type: 'vfat',
size: 1124999168,
used: 6369280,
available: 1118629888,
use: 0.57,
mount: '/mnt/host/boot/efi',
rw: false
},
{
fs: '/dev/sda1',
type: 'ext4',
size: 3936820690944,
used: 1772756307968,
available: 1964008259584,
use: 47.44,
mount: '/mnt/host/mnt/media',
rw: false
}
] Also, here is the output of
|
Hi. dashdot/issues/1032 has updates. After upgrade latest system packages problem resolved. But I can't explain which package. Also attached my log of updates included in fedora 39 |
@MauriceNino ... concerning the last message here: so we can close this issue?? |
@sebhildebrandt No, unfortunately, it still seems to me like there are some issues that could be resolved. The output of If you have already checked it and there seems to be nothing wrong with Thank you for taking your time with this though :) |
For node alpine containers the only solution that I have found for this is to install coreutils:
The reason is the following: In the file
This fails because busybox
This command succeeds but also can include some content in stderr (even though there are valid entries in stdout). Specifically the content in stderr is about the paths like However because there is a difference in how the output is handled in the fallback command, if there is any content in stderr, the following lines never execute: if (!error) {
let lines = filterLines(stdout);
data = parseDf(lines);
} Because of this the data variable that is passed as the result to the callback or the resolve of the Promise is an empty array. |
Describe the bug
I am using
systeminformation
on my project inside a docker container, and some users (mostly Ubuntu 22-23) reported thatfsSize
returns an empty array.To Reproduce
Hard to reproduce, as I can't really do so with my system either. It is a common error though, so you can look into MauriceNino/dashdot/issues/944 or MauriceNino/dashdot/issues/1032.
Current Output
Output gathered by user @SecOps-7, who is one of the users encountering this problem.
docker exec Dashdot df -kPT
Environment (please complete the following information):
Additional context
I tried parsing the output above with your code as well, but managed to do so just fine, so I am wondering which part is making the problems?
Example
Output:
Do you have any idea?
The text was updated successfully, but these errors were encountered: