New answers tagged

2

df reads /etc/mtab to find what device is mounted on a particular mount point. This can either be a file which is updated by the mount command, or a symbolic link to /proc/mounts which contains current information provided by the kernel. /etc/mtab has the advantage that it can provide more precise information: it's what was passed to mount, not some ...


0

You can combine the two approaches, do cross compilation with multiarch for dependencies but use a dedicated chroot for each target architecture. This way you won't have as many problems with conflicts. I can't gaurantee that it will work for your package but it has a much better chance that trying to do all architectures under the same root filesystem.


2

Chroot is the more traditional way of doing this, and you can make it work, but since you're doing this via a web interface, it gets a little complicated: you must prevent race conditions (multiple users from using the same chroot environment), you must dynamically build a directory structure for each request, and probably a few other things I can't think of ...


0

This has been answered a number of times online, these two look like a pretty good place to start: What's the proper way to prepare chroot to recover a broken Linux installation? How to restore a system after accidentally removing all kernels? If you have specific problems while going through a tutorial you can create a question for that (provided it ...


2

A user can access any directory they create, so unless you're going to give the user a home directory without write access, they will be able to create a public_html directory and access it. If you are using the userdir apache module, you can use a custom name or set up the Apache configuration to have a Require all denied directive for locations in that ...


0

This tool could be handy: chname Run command or interactive shell with a new system hostname SYNOPSIS chname hostname [command ...] DESCRIPTION Create a new utsname namespace with a new system hostname and execute command. This is particularly useful for creating a chroot that has a hostname independent of the rest of the system. ...


0

systemd-nspawn --network-interface=ppp0 ppp0 will disappear from the host namespace. You can't share one IP address with a container and not your other IP addresses. (Apart from doing NAT). It looks like this might require a very recent kernel though. http://www.spinics.net/lists/netdev/msg339236.html OR (machine is created after ppp0): ...


2

To set up networking for your chrooted session you need to copy the DNS configuration into the chroot environment : cp /etc/resolv.conf /mnt/etc/resolv.conf Or ln -s /etc/resolv.conf /mnt/etc/resolv.conf


0

To properly secure ssh access, you must not allow authentication free login. Set up an RSA key for authentication, and then the client can use that instead of needing a password.


2

You need to tell PAM also that you want to allow empty passwords. There is some outdated tutorial describing that. But in short: sudo sed -i 's/nullok_secure/nullok/' /etc/pam.d/common-auth should do the job.



Top 50 recent answers are included