-
Smithx10
No hockey tomorrow, just let me know what to do, im a bit confused
-
Smithx10
maybe ill try zdb -dddd zones/$dataset
-
Smithx10
-
Smithx10
so it looks like..... from that output.... there are a lot of ZFS plain file and ZFS directory that write 512 bytes but take up a 128k block "47087 1 128K 512 0 512 512 100.00 ZFS plain file"
-
bahamat
Yeah, that's what it looks like.
-
Smithx10
Percent empty: 78.749621
-
Smithx10
So..... what is writing out the large amount of /system/contracts?
-
Smithx10
is that normal?
-
Smithx10
-
Smithx10
has a list of du --inodes sorted
-
bahamat
Well a contract is a group of processes
-
bahamat
SMF, for example, each service runs in a contract.
-
Smithx10
What's that behavior like?
-
Smithx10
Does every process that spins up in lx create a directory / file in contracts?
-
bahamat
No. Having 918k of them seems like way too many
-
Smithx10
This box has been up 00:42:06 up 224 days, 4:37, 4 users, load average: 0.23, 0.26, 0.25
-
bahamat
I mean maybe...
-
bahamat
but for example one of my LX zones, I've zlogin'd to it. The zlogin is under a contract
-
Smithx10
prstat shows Total: 33 processes, 301 lwps, load averages: 0.23, 0.26, 0.26
-
bahamat
dhcpagent, which is running out of /native and is spawned by hypervisor is in another. All other processes are grouped into a single contract.
-
Smithx10
20220505T001410Z
-
Smithx10
-
Smithx10
Any ideas on what could change that behavior ? Is it safe to rm -rf /system ?
-
bahamat
No
-
bahamat
But if you reboot the zone I think it'll clean it all up
-
Smithx10
I'll ask them to bounce
-
Smithx10
Guessing /system/contracts doesn't clean up ?
-
bahamat
I think it should.
-
Smithx10
Any logs I should check to see if its having issues doing that?
-
bahamat
I don't think so. IIUC that whole directory is managed by the kernel.
-
rmustacc
/system/contract is backed by ctfs.
-
rmustacc
So it's entirely synthetic.
-
rmustacc
So I don't think there's anything to do from a user perspective there.
-
bahamat
But it seems odd to me that there'd be 918K files in it.
-
rmustacc
Not disagreeing there.
-
bahamat
But being ctfs backed, a reboot should clear that up, shouldn't it?
-
rmustacc
Probably, yes.
-
rmustacc
Is this causing a cascading problem?
-
rmustacc
Though probably I would try to figure out what's in there or take a dump if you're going to reboot.
-
bahamat
Well, this stemmed from trying to find out where all the space went.
-
rmustacc
I do not believe that any zfs space is used by that file system.
-
bahamat
The zone is using about 13G, but is consuming about 20G
-
rmustacc
But we can check the underlying impl.
-
rmustacc
But I think every ctfs node is anonymous kernel memory.
-
Smithx10
Above there is a link to the sorted inodes on the lx zone
-
rmustacc
But since you transition to another mount point I don't think that would be backed by zfs.
-
Smithx10
I guess we could just inode count x 128 k and see if it even makes sense
-
rmustacc
The ctfs_mount doesn't have a hold to the underlying file system that's immediately obvious.
-
Smithx10
The zdb output has a lot of empty looking files that don’t show the path
-
Smithx10
Errr not files *. Objects
-
rmustacc
I've spent very little time so could be something else ultimately.
-
Smithx10
was on my phone, jsut got back on the lt
-
nahamu
zomg. since it's a very self-contained golang binary program, I can just pull in the package from nearly any existing zone:
-
nahamu
-
Smithx10
-
Smithx10
Does a symlink take up a recordsize in zfs?
-
bahamat
Yeah, it's a file
-
Smithx10
Still not 100% certain whats taking up all the space, heading to bed tho
-
Smithx10
Worked with some folks over in #openzfs and found out that a lot of space was stuck in the "on delete queue" via zdb
-
Smithx10
looked into that, and restarted "promtail"
-
Smithx10
which is some grafana logger rotatter thingie
-
Smithx10
im guessing promtail was keeping them open
-
Smithx10
Not sure if its LX, or Just Illumos, but some windows folks
grafana/loki #3668#issuecomment-1252441103 ran into this
-
Smithx10
sigh
-
jperkin
I run grafana on native but not promtail, sorry, so can't vouch for it being an issue on illumos
-
neuroserve
Smithx10 - do you have the promtail config?
-
Smithx10
-
neuroserve
thats basically two logs (/var/log/messages and /var/log/haproxy.log)
-
jbk
Smithx10: i wonder if it periodically would stat the fd it's tailing and if it sees the link count drop, if it'd stop tailing the file or not..
-
jbk
it seems like that would solve the issue... but also not something i've ever tested...
-
neuroserve
Smithx10 : do you know the promtail version, too?
-
Smithx10
version 1.6.1
-
neuroserve
ok - I've got 2.5.0 - current seems to be 2.7.1
-
Smithx10
Whats the command to get the SN for a disk ? SCSI c3t5000CCA27077CE29d0 HGST HUH721212AL4200 11176.00 GiB no no
-
bahamat
The most reliable way is iostat -En
-
jbk
diskinfo -P ?
-
bahamat
`diskinfo -c` can, but often times can't find it. It was never clear to me why, but it's apparently because they enumerate disks in a different way.
-
Smithx10
Anyway to light it up from within SmartoS?
-
Smithx10
trying to blink it so it can eb replaced
-
bahamat
Yeah, but it's not straightforward.
-
jbk
yeah, i notice with my internal nvme disk that diskinfo doesn't show the serial.. but i think that might be because i'm using a custom topo map that doesn't enumerate the location right now
-
bahamat
Smithx10: Ok, so use iostat -En to get the serial number of the device
-
bahamat
Then use /usr/lib/fm/fmd/fmtopo to dump devices. Find your serial number to get the enclosure and bay number
-
bahamat
Then use /usr/lib/fm/fmd/fmtopo | grep indicator and look for your enclosure/bay to get the fmri of the device
-
bahamat
Then use `/usr/lib/fm/fmd/fmtopo -P facility.mode=uint32:1 <fmri>?indicator=ok2rm` to turn the light on
-
bahamat
to turn the light off, do the same command but use uint32:0 instead
-
Smithx10
Then use /usr/lib/fm/fmd/fmtopo to dump devices. Find your serial number to get the enclosure and bay number dont see the serial number, do I need to turn up the output?
-
Smithx10
-
bahamat
As far as I know, there's not a way to increase the verbosity.
-
bahamat
The serial is usually part of the FMRI.
-
bahamat
I have an m2 SSD in my headnode, and I don't even see anything that might be it in the fmtopo output :-(
-
Smithx10
this is what i get from topo
-
Smithx10
-
bahamat
So starting on line 567 is scsi-devices
-
bahamat
But that doesn't even have serial numbers in the FMRI...
-
bahamat
So, no idea...
-
Smithx10
./shrug wonder if I can do this in super micro oob
-
bahamat
Yeah, I don't know. rmustacc would probably be the best person to ask to better understand this stuff.
-
bahamat
He's the one that showed me how to drill down to light up the light.
-
bahamat
But fmtopo often defies my expectations. I really don't understand it well.
-
bahamat
I gotta take off. Back in about an hour.
-
Smithx10
lol, this seems like it shouldnt be so hard rofl
-
rmustacc
Smithx10: Can you add -V to your fmtopo command?
-
Smithx10
-
rmustacc
So this is a platform Joyent had a map for. So diskinfo -P should have told you the slot.
-
rmustacc
Did it not?
-
Smithx10
-
rmustacc
Curious, that's odd.
-
Smithx10
-
rmustacc
Right, this is a system we specifically designed all this support for back in the day.
-
rmustacc
Is ses not reporting anything on that system?
-
Smithx10
what is "ses"?
-
jbk
scsi enclosure services
-
Smithx10
How do I tell?
-
jbk
basically it's a device that lives on the SCSI bus/fabric that manages an enclosure.. so it's what handles things like indicator/fail lights, power for a disk bay, fans, ...
-
rmustacc
Do you have anything like a /dev/es/XXX? IIRC.
-
Smithx10
-
rmustacc
You can ask sestopo for more info there. I don't know why fmtopo doesn't have the ses enumeration.
-
Smithx10
-
jbk
i've been told that the SES devices can be a bit loose with the spec
-
jbk
and that there's a lot of 'we'll just document how it works today vs. how it should work'
-
Smithx10
:(
-
Smithx10
gotta boot up linux to run lldp during our next expansion :(
-
jbk
you use aggrs, right?
-
neuroserve
Smithx10 : still that lldp problem?