Community Forums
Connect with us on LinkedIn
+ Reply to Thread
Results 1 to 6 of 6
  1. #1
    Member manokiss's Avatar
    Join Date
    Mar 2002
    Posts
    536

    Question jailed shell bug?

    cPanel uses virtfs for its shell jailing. Virtfs is a system which creates a
    virtual filesystem in which a user is restricted to which simulates a real
    fully functional system within the server.

    When cPanel creates the jail shell environment for a user, it creates a
    directory in /home/virtfs/ with the name of the username, similar to the
    entry in /home/. In this directory, cPanel places files that creates the
    environment of the jailed shell, as well as copies the user's files in
    /home/virtfs/<user>/home/ in a directory of the username, essentially
    emulating the real environment without the rest of the users.

    The problem with this is cPanel is copying the files, so the user has
    duplicate files, and quota usage doubles. What should happen instead is
    cPanel moving to full virtfs support where /home/<user>/home/<user>/ becomes
    the site root so virtfs files can be placed in /home/<user>/, or there
    should be a symlink created to the user's files from
    /home/virtfs/<user>/home/<user>/ pointing to /home/<user>/.

    This is not only a problem with user quotas, but also with disk usage. A
    server which has multiple large sites with jail shell access could consume
    the entire hard drive fairly quickly.


    Beau Steward
    Systems Engineer

  2. #2
    Member
    Join Date
    Jul 2002
    Location
    Atlanta, GA
    Posts
    646

    Default

    Incorrect. It does not duplicate the user's home directory. It simply configures a placeholder that virtfs references.

    Quotas are not doubled. Run a scan of disk usage on the user's actual home directory and then check their quota. They will be roughly the same.

  3. #3
    Registered User
    Join Date
    Sep 2004
    Posts
    1

    Default

    I have a problem at the moment similar to this. A 'du -h' in my home directory shows I've used 217 mb, but CPanel thinks I've used 433mb!!! My hosting provider seem inept at resolving this issue, and at the moment I'm loosing emails because it thinks I've exceeded my quota (300mb). Grrr.

    Lyndon

  4. #4
    cPanelBilly
    Guest

    Default

    when /scripts/fixquotas run it updates the quotas, any user that is logged in with jailsheel is immediatly logged out and told not to log back in for 30min to prevent this from happening.

  5. #5
    Member
    Join Date
    Aug 2005
    Posts
    35

    Default

    Hey billy, how does one go about purging this /home/virtfs directory safely? Someone suggested disabling and enabling jailshell in WHM, would this work ?

    Also, in regards to that other users problem whose host thinks he's exceeded quota : I notice that these files are owned root.user . I don't have this problem as of yet, but i've definitely seen this as a problem where a file is owned by the user outside their account and is added up in their quota. Will this be a problem or will the "root" owner prevent that ?

  6. #6
    Member
    Join Date
    Aug 2005
    Posts
    35

    Default

    ....nm.. I think I understand now... a bunch of links.. not actual space, just the combined total of their linked directory... Quotas thing makes sense too... i've not had that problem yet, but better to know beforehand.

Similar Threads & Tags
Similar threads

  1. Problem with jailed shell
    By Xylitol in forum cPanel and WHM Discussions
    Replies: 1
    Last Post: 02-25-2008, 09:37 AM
  2. Jailed shell
    By codebirth in forum cPanel and WHM Discussions
    Replies: 2
    Last Post: 10-11-2007, 12:55 AM
  3. jailed shell access - how does it differ from normal shell?
    By spaceman in forum cPanel and WHM Discussions
    Replies: 1
    Last Post: 08-04-2004, 11:08 AM
  4. Jailed Shell
    By Dathorn_ADT in forum cPanel and WHM Discussions
    Replies: 3
    Last Post: 11-07-2003, 11:54 AM
  5. su in jailed shell
    By Alarion in forum cPanel and WHM Discussions
    Replies: 11
    Last Post: 05-06-2003, 04:58 PM
Linkedin       Facebook       Twitter       RSS       Flickr       YouTube