CLI tips to manage CageFS – cagefsctl command for CloudLinux server

CloudLinux is a Linux based Operating system especially used in a shared environment which isolates each user in its own light weight virtualized environments (LVE) which consumes predefined amount of resources allocated for each user. We already covered some topics on CloudLinux. >> CloudLinux installation <<

The command-line tool for managing CageFS is cagefsctl. Here I’m explaining some important commonly using cagefsctl commandline switches.

The installation path is : /usr/sbin/cagefsctl

Switches and examples of cagefsctl

1) This command initialize CageFS on server (create CageFS if it does not exist). This is important while completing the CloudLinux installation.

-i or --init

2) Reinitialize CageFS (make backup and recreate CageFS).

-r or --reinit

3) Update files in CageFS (add new and modified files to CageFS, remove unneeded files).

-u or --update

4) Recreate CageFS (do not make backup, overwrite existing files).

-f or --force

5) Mount and Unmount CageFS skeleton directory


6) Enable and disable CageFS


7) To update CageFS forcefully.


8) Forces clean up of all user’s tmp directories.


9) Remount specified user(s)

-m or --remount

10) Restart cagefs-fuse service, remount CageFS skeleton directory and all users, (use this each time you have changed file)

-M or --remount-all

11) Unmount specified user(s)

-w or --unmount

12) stop cagefs-fuse service, unmount CageFS skeleton directory and all users

-W or --unmount-all

13) Managing user’s -CageFS


-l or --list :: list users that entered in CageFS
--enable :: enable CageFS for the user
--disable :: disable CageFS for the user
--enable-all :: enable all users, except specified in /etc/cagefs/users.disabled
--disable-all :: disable all users, except specified in /etc/cagefs/users.enabled
--display-user-mode :: display current mode ("Enable All" or "Disable All")
--toggle-mode :: toggle mode saving current lists of users, (lists of enabled and disabled users remain unchanged)
--list-enabled :: list enabled users
--list-disabled :: list disabled users

Reference : CloudLinux Doc

Also read

1) Introduction to CloudLinux and installation guide
2) Introduction to CageFS and PHP Selector and installation – CloudLinux

Arunlal Ashok

Linux Server Administrator. I'm dealing with Linux servers since 2012. I started this blog to share and discuss my ideas with the world. Check My Profile!! in uPwork (oDesk) and let me know if you need any assistance. Thanks!!

You may also like...

Leave a Reply

Your email address will not be published. Required fields are marked *