Results 1 to 3 of 3

Thread: question on where to place my addition to this script.

  1. #1
    Just burned their ISO
    Join Date
    Oct 2012

    Default question on where to place my addition to this script.

    Morning all, what im trying to do today is make my distro of BackTrack automatically startx.

    Here is the script I am instructed to edit.

    #!/bin/sh -e
    # rc.local
    # This script is executed at the end of each multiuser runlevel.
    # Make sure that the script will "exit 0" on success or any other
    # value on error.
    # In order to enable or disable this script just change the execution
    # bits.
    # By default this script does nothing.
    exit 0

    Now here is what I am supposed to add

    just add this line : su -c root startx
    in /etc/rc.local
    save and reboot your system

    where in the above script would i place this? I'm afraid to add it without confirmation as I may cause non-reversible damage

  2. #2
    Senior Member VulpiArgenti's Avatar
    Join Date
    Sep 2011

    Default Re: question on where to place my addition to this script.

    # By default this script does nothing.
    exit 0
    You shouldn't be afraid to try things out - how else are you going to learn? I have borked my install of BT many times in the past, and will probably do so again one day.

  3. #3
    Very good friend of the forum maverik35's Avatar
    Join Date
    Sep 2009
    Debian land

    Default Re: question on where to place my addition to this script.

    You will cause nothing...And if you mess up, there are ways to fix it..

    First, if you are trying to run a service during booting, let me ask you something: Why are you trying to do something you do not know how it works?...I'm not saying the info at some site is wrong, all I'm saying is that you need to know before doing something...

    You have to know a little bit of runlevels.

    Second: do you know the multiuser runlevels?..I'm sure you don't..Runlevels are 0-6, S, 7-9..
    Runlevel 0 -----Shut down or HALT system
    1------Mono user. Just one console activated for one user, the ROOT.
    2------Multiuser with NFS (Network file sharing)..
    3------Multiuser with Network Services
    4------Not used (can be used by user)
    5------Multiuser with Network Services and X
    7-9 are not used

    All runlevels have LINKS to the scripts under /etc/init.d/"name"...Those scripts are installed by the package installed using post-installation script, per say: I install WICD, the package will use a post-installation script to create the script in /etc/init.d/wicd and a link in the runlevel..
    You can insert links in runlevels 2 ways: Legacy mode using commands to decide the runlevel and sequence (update-rc.d) and the default mode using the Tags (LSB) in the headres of scripts (/etc/init.d/"name" using insserv).

    Read first and if any doubt, post it to help..Let me give you a huge Help: Open a terminal and issue: "man update-rc.d"..Read it as many times as youy can, as I did 5 months ago, and still do...Then you come back and you will see the problem in a different way...

    Last edited by maverik35; 12-15-2012 at 11:24 AM.

Similar Threads

  1. Addition - Mallory: Transparent TCP and UDP Proxy
    By Mr-Protocol in forum Tool Requests
    Replies: 3
    Last Post: 09-07-2010, 10:18 AM
  2. Meterpreter killav.rb script question
    By ben015 in forum Experts Forum
    Replies: 2
    Last Post: 04-23-2010, 10:38 AM
  3. Suggestion: Addition to Install.txt
    By imported_wyze in forum OLD BT3beta General
    Replies: 1
    Last Post: 12-20-2007, 01:33 PM
  4. Request: Forum Rules (Guidelines) Addition
    By thorin in forum OLD Feature requests
    Replies: 14
    Last Post: 11-02-2007, 08:19 PM
  5. Best place to call a shell script for autostart
    By g1ic7h in forum OLD Newbie Area
    Replies: 4
    Last Post: 08-17-2007, 11:36 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts