A chroot on Unix operating systems is an operation that changes the apparent root directory for the current running process and its children. A program that is run in such a modified environment cannot name (and therefore normally not access) files outside the designated directory tree.

learn more… | top users | synonyms

1
vote
1answer
22 views

sbuild schroot fails

I am trying to package an Ubuntu package as a Debian package. For maintainability I am trying to use sbuild. Following the steps here I go through the first five steps, but when I try to build I get ...
0
votes
0answers
33 views

Directory does not exist inside the chroot

I'm trying to setup an ubuntu scope project using the setup wizard from the ubuntu sdk ide. The last step in this wizard is to run cmake, but I get the following error: E: Failed to change to ...
0
votes
0answers
21 views

file permissions is getting differed with the umask value while using sftp

I have set up the jail rooted sftp environment on port 222 with umask 0002. I have created the jail rooted user whose home directory is on nfs mount point. When I have tried to upload the files , I ...
1
vote
0answers
23 views

How to 'snapshot' a chroot?

I want to perform something similar to a 'clone' on vmware fusion/virtualbox/a VM manager. Host and chroot are both ubuntu. One complicating factor may be that this chroot may have one or more child ...
0
votes
0answers
13 views

Change permissions of /opt folder [duplicate]

Maybe this is dumb from the security point of view. But I would like to change permissions of /opt folder to 775 (or 777). Enabling the user to modify its content. Is this ok or does that pose a ...
3
votes
1answer
30 views

How to detect the architecture of the chroot from inside the chroot?

Let's say for example the host system is running Debian amd64. And on that system, another Debian i386 has been installed inside a folder using debootstrap. Then assume a shell script is running ...
0
votes
1answer
27 views

How to run command after entering postgres

I am trying to execute ls after opening a new Guake tab and logging into postgres. guake -n guake -e 'sudo -i -u postgres && ls' The command successful opens a new tab then prompts me for ...
1
vote
0answers
30 views

Build errors on a copied operating system in a chroot

I'm in a bit of an interesting situation. In an attempt to have root access on my school's physics network computers, I ended up creating a chroot environment, using fakeroot and fakechroot. As every ...
1
vote
1answer
59 views

debian jessie volume group not found and cant boot

I have accidentally deleted my boot partition. OS is Debian Jessie with LUKS LVM. I have created a new partition and successfully reinstalled grub with chroot method. Now when I try to boot, my root ...
0
votes
1answer
31 views

How to protect from chrooting to its linux partition and how to chroot it after using the protection?

I am currently using archlinux, It is possible to boot on an archlinux installation iso for instance, to mount my current archlinux partition and my boot partition and then to use arch-chroot. Then I ...
0
votes
0answers
57 views

bash errors getcwd: cannot access parent directories

I cross-compiled GNU bash v4.3 but am now getting errors related to: shell-init: error retrieving current directory: getcwd: cannot access parent directories: Function not implemented and chdir: ...
1
vote
1answer
41 views

How can I use debian_chroot in bashrc to identify the chroot env?

I see the following in ~/.bashrc : if [ -z "${debian_chroot:-}" ] && [ -r /etc/debian_chroot ]; then debian_chroot=$(cat /etc/debian_chroot) fi which means if the variable is ...
1
vote
1answer
35 views

How can I boot into a chroot, without leaving the current OS session?

I'm building Linux systems, turn them into ISOs and then test them in a VM. But that step takes minutes, which I would like to avoid, while developing. Is there a way I can take the files, which are ...
1
vote
0answers
34 views

Trigger a GTK application from CHROOT during LightDM startup

I am trying run a GTK application with chrooted environment. Mentioned are the lightdm settings which I have set. System configuration: OS : Debian 8 chroot FS: Debian 6 Windows manager : LXDE ...
0
votes
2answers
29 views

how to mount -t proc proc proc/ with their absolute path for a chroot?

as we know chroot needs some fs to be mounted inside chroot directory like the following : chroot_dir=/some/where cd $chroot_dir/ mount -t proc proc proc/ mount --rbind /sys sys/ mount --rbind ...
1
vote
2answers
24 views

How is OpenSSH sftp jail/chroot working?

This question is actually too broad... What I really want to know is whether or not it actually chroots and, if so, how a SSH user deamon[1] can be launched in that jail in spite of the obvious lack ...
2
votes
1answer
50 views

Is there a way to isolate a running program from the rest of a Linux system?

First of all, I know about virtualisation and containers. I'm sure "he wants containers" is what popped in your mind. (Don't deny it!) However containers are like chroot: if you want to execute bash ...
1
vote
0answers
94 views

unix chroot jail shell (with or without sudo?)

at the moment I am creating a chroot jail. Therefore I read some articles and everything seems to be clear, exept for one thing: the chroot jail shell In one source they created the following setup ...
1
vote
0answers
24 views

How to give chroot ssh access user access to /var/www/html [duplicate]

I followed this guide to set up chroot access for a vendor to our web server: http://geek.co.il/2010/03/14/how-to-build-a-chroot-jail-environment-for-centos It works and I have a chroot jail set up, ...
0
votes
0answers
13 views

Creating Ubuntu Gutsy chroot on Mint 17.1 fails to download Packages.bz2

I am trying to create a chroot to Ubuntu 7.10 on host running Linux Mint 17.1 64-bit. For that, I first created an entry in /etc/chroot/chroot.conf [gutsy] description=Ubuntu Gutsy location=/genera ...
3
votes
0answers
20 views

chroot and hyperos on ArchLinux?

hyperos is a fork of tinycorelinux Can I run hyperos in a chroot? How can I create an ISO image from files on repo? Is this possible? Which steps should I follow?
1
vote
0answers
36 views

SFTP chrooted to home directory and users wanted to have a write permission to home directory [duplicate]

I have a new request from the user and these are the following requirements Request to have an sftp user account and disable shell access Sftp User should only see their home directory (ie.. ...
5
votes
1answer
68 views

PID in arch-chroot is incorrect

I am trying to run a python script in a chroot (specifically, the chroot is created with arch-chroot). The python script relies on os.getpid(), but this seems to be returning an incorrect PID within ...
1
vote
1answer
78 views

pid file error when starting stunnel

I'm trying to start stunnel at my mac os as client. But I'm not able to get it running as I have noticed this reported problem at the stunnel's log file: 2015.10.10 16:10:24 LOG5[ui]: stunnel 5.23 on ...
3
votes
1answer
136 views

SELinux and chroot system call

TL; DR: This is a question about the final step, in a portable, developer-oriented rooting process, that works across all Android machines. It is not based on any exploit - it is something that we are ...
1
vote
2answers
36 views

How to create 32bit chroot system that is just a mirror of my current system for compiling purposes?

After lot of googling and posting and crying over obscure GCC linker error messages I concluded that the only way to reliably build something in foreign CPU architecture is to set up a chroot ...
3
votes
2answers
61 views

debian: unnecessary essential packages in a chroot environment

I have set up debian 8 (jessie) in a chroot environment (on an android phone, but that is not important to this question), and noticed that it is quite large. I have then removed all packages that are ...
1
vote
1answer
63 views

Arch - How do Install a package made in a clean chroot?

I've been trying to build and install GNU Icecat from source on Arch linux using yaourt, but I've recieved errors during the build relating to the Infinality font set. I came across this page from ...
1
vote
1answer
28 views

enable a user to chroot?

I have a script that I am running as a regular user (but one that can sudo). This script relates to BIND and gathers information each time it runs. It has not been working correctly and I noticed ...
1
vote
0answers
32 views

How does a chroot system interact with the kernel

I am trying to debug an OpenGL issue in a piece of closed source software. The software supposedly works in Debian Wheezy and I would like to get it working in Arch. I tried running it in a Debian ...
2
votes
0answers
87 views

Restrict SFTP users to different directories

How can I restrict some users/groups to some directories? I mean different users, different directories. What I have: Ubuntu 14. Experience with Ubuntu: Just started. What I have tried: I read ...
0
votes
1answer
28 views

Why am I getting kicked out of my chroot?

I enter a chroot, source a script to initialize my git user (source init_my_chroot) and then seem to be too sensitive to getting kicked out of my chroot. install: cannot create regular file ...
1
vote
1answer
24 views

how to avoid direct/network root login on the system and using some chroot to admin the system?

here the idea for which I seek a solution: I want to have a system with no way to log as root. I want to manage the system (edit /etc/files, (un)install something, etc.) by physically unplug the ...
2
votes
2answers
78 views

Does it make sense to use SELinux inside a chroot jail?

Does it make sense to use SELinux inside a chroot jail? I am thinking that since in the chroot jail there should only be the bare minimum, not much else could be compromised. Is there still a benefit ...
1
vote
2answers
23 views

Pureftpd as user,is possible?

I want to run pure-ftpd in chroot as user,not as root,i've set server to non privileged port 5050,but i don't know how to run as user instead of root,someone know the option?
0
votes
1answer
143 views

Can't find job mysql on crouton, ubuntu precise

I'm using Ubuntu precise as chroot in my chromebook machine. I'm trying to install mysql through apt-get install mysql-server. The thing is, when I try to start it, it can't find the job: ...
0
votes
1answer
65 views

Chroot - copy or mount --bind

In every tutorial I found online about chrooting, there is part involving copying stuff into the chroot, executables, libraries and others. Why is that? Why not just mount --bind the stuff in? ...
0
votes
1answer
68 views

Pass environment variables to clean chroot in Arch

I am writing a PKGBUILD for Arch Linux. The package is large and compressing/uncompromising it take considerable time for limited space savings and I would like to turn it off while I am writing the ...
1
vote
1answer
142 views

How to create a tar of a chroot?

I want to capture everything in a chroot but am unsure whether I need to first chroot into it to see the full filesystem/preserver permissions etc. From outside the chroot, it seems like I would miss ...
2
votes
0answers
64 views

running cron on a chroot

For my web development I use a debootstrap'ped Debian with sysvinit, I start apache2/mysql manually only when I need to work. Now for a new project I require to run some scheduled task for which I ...
0
votes
1answer
25 views

What happens if I mount multiple devices at the same path in chroots?

I'm trying to understand what happens if multiple change roots mount to my host's /proc directory. sudo chroot mychroot1 mount -t proc proc /proc sudo chroot mychroot2 mount -t proc proc /proc ...
1
vote
1answer
38 views

Is it possible to chroot sftp service as unprivileged user?

I currently have an sftp-only sshd service running as an unprivileged user that works fine. When adding ChrootDirectory %h to the separate user_sshd_config, the user is immediately disconnected after ...
0
votes
2answers
37 views

How to pass an environment variable when change rooting?

I don't seem to be able to pass an environment variable to a chroot: $ sudo apt-get install debootstrap dchroot $ sudo debootstrap trusty mychroot $ sudo chroot mychroot /bin/bash -c "MY_VAR=5; echo ...
2
votes
2answers
61 views

Using a file other than /etc/resolv.conf to specify a DNS server

Is there a way to specify the address of a DNS server outside of using /etc/resolv.conf? Reason: ( since someone will ask ) I have a system running LDME 1. I have installed a new drive and on it LDME ...
2
votes
1answer
109 views

chpasswd apply changes in the chroot directory

I have debootstraped version of wheezy on my Archlinux machine and would like to change it's root password: echo "root:toor" | chpasswd --root /home/containers/wheezy/ However I get an error: ...
2
votes
2answers
104 views

chpasswd apply changes in the chroot directory [duplicate]

I have debootstraped version of wheezy on my Archlinux machine and would like to change it's root password: echo "root:toor" | chpasswd --root /home/containers/wheezy/ However I get an error: ...
1
vote
1answer
72 views

Running ssh from chroot jail in SuSE

I'm trying to make a server that acts as sort of an access point for lots of other machines. I want to give one user jailed access to it so they can ssh to other machines in the network. I've got ...
1
vote
1answer
125 views

Set up enviroment for cross-compilation to i386, armel, armhf, arm64 and mips with no libglib2 conflicts

I'm trying to set up a build environment for a software in Debian Jessie. I need to produce amd64, i386 and eventually armel and armhf binaries of the software. It would be cool if I could ...
1
vote
0answers
11 views

Chroot Users to /opt and subdirectories [duplicate]

I'll make this short and hopefully I make sense. Im trying to give a user ssh access, but, he/she must only be able to access /opt and the few subdirectories that live under it. However, here's ...
3
votes
0answers
132 views

Sound output not working properly in chroot

So I have a 64-bit Linux Mint 17 system and I am trying to set up a chroot environment with a 64-bit Ubuntu 12.04-based system (actually something called Vinux, an Ubuntu remix). The problem is that ...