Openstack Ansible
Gk Gk
ygk.kmr at gmail.com
Mon Jun 5 12:12:44 UTC 2023
But when I check it from the host, it is still showing incorrect usage:
---
du -sh /var/lib/lxc/example_repo_container-237946ab/rootfs/root/
36K /var/lib/lxc/example_repo_container-237946ab/rootfs/root/
--
How to get its correct usage then ?
On Mon, Jun 5, 2023 at 5:15 PM Dmitriy Rabotyagov <noonedeadpunk at gmail.com>
wrote:
> Hi,
>
> I don't think this is possible.
> Disk usage of containers should be performed from the host rather then
> container. Unfortunately, with current default backing store (which is
> `dir`), there's no neat way of doing that. So you'd need to use smth
> like `du -sh /var/lib/lxc/<container_name>/rootfs/` to check how much
> diskspace it's consuming. Though, backing store is customizable. So
> you can set `lxc_container_backing_store` variable to "lvm" or "zfs"
> and check diskspace consumption per lvm/zfs volume.
>
> пн, 5 июн. 2023 г. в 09:56, Gk Gk <ygk.kmr at gmail.com>:
> >
> > Hi All,
> >
> > We have an OSA setup. When I check the usage of filesystem of any
> container using "df" command, it shows the lvm partitions of the underlying
> host as well as shown below:
> > --
> > Filesystem Size Used Avail Use%
> Mounted on
> > /dev/mapper/lxc1-lv_root 86G 60G 22G 74%
> /
> > none 492K 4.0K 488K 1%
> /dev
> > /dev/mapper/lxc-openstack 493G 136G 334G 29%
> /var/log
> > tmpfs 252G 0 252G 0%
> /dev/shm
> > tmpfs 51G 88K 51G 1%
> /run
> > tmpfs 5.0M 0 5.0M 0%
> /run/lock
> > tmpfs 252G 0 252G 0%
> /sys/fs/cgroup
> > example:gfs-repo 86G 67G 16G 82% /var/www/repo
> > ---
> >
> > How to exclude the host partitions such that df only reports the
> container usage only ?
> >
> > Thanks
> > Kumar
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.openstack.org/pipermail/openstack-discuss/attachments/20230605/6e98bf6a/attachment.htm>
More information about the openstack-discuss
mailing list