Giter Site home page Giter Site logo

chroot-debian's Introduction

Debian chroot environment

This scripts helps to install Debian 8 services on MIPS routers with Padavan firmware.

Prerequisites

Prepare Ext2/Ext3/Ext4 partition on USB drive by following this manual. Clean Debian environment takes ~300MB. SWAP usage is also recommended (especially on 64MB RAM devices).

Installation

It takes few minutes to download and unpack ~50MB archive. Log into router's SSH/telnet/serial console and type:

wget --no-check-certificate https://raw.githubusercontent.com/DontBeAPadavan/chroot-debian/master/install.sh
sh install.sh

If all goes as expected, you'll get:

Downloading /opt/etc/init.d/rc.func... success!
Downloading /opt/etc/init.d/rc.unslung... success!
Downloading /opt/etc/init.d/S99debian... success!
Downloading /opt/debian_clean.tgz... success!
Unpacking Debian environment... success!
The Debian services from /opt/debian/chroot-services.list will be started automatically at boot time. You may log into Debian environment via SSH root:[email protected]:65022. Do you wish to start it now? [y/n]: y
Starting Debian services...
[ ok ] Starting OpenBSD Secure Shell server: sshd.
Done.

Usage

Log into chroot'ed Debian environment by root:[email protected]:65022 where 192.168.0.1 is the IP address of router. You've got full blown Debian on board with all it's 40+ thousands packages! Let's install transmission as an example:

apt-get update
apt-get install transmission-daemon
echo 'transmission-daemon' >> /chroot-services.list

The last command adds transmssion to the list of Debian services, which is started at boot time. transmission-daemon is the script name from /etc/init.d/<name>.

This is just a sandbox, which is isolated from host system. If you'll break it, you can always start from scratch. Log into router console and run:

cd /opt
/opt/etc/init.d/S99debian stop
rm -fr debian
rm /opt/etc/init.d/S99debian
sh install.sh

Voilà! You've got fresh Debian installation again.

Details

The installation script unpacks prepared Debian environment. You can prepare it manually, see how.

Also, take a look at /opt/etc/init.d/S99debian. You can mount any host folder as /media in Debian env. by setting $EXT_DIR varialble. It's a "bridge" between host and chroot'ed systems.

Good luck!

chroot-debian's People

Contributors

ryzhovau avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.