LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 12-02-2006, 07:19 PM   #1
polarbear20000
Member
 
Registered: Oct 2006
Location: Crestview, FL
Distribution: Slackware 13, Debian 8.1
Posts: 99
Blog Entries: 1

Rep: Reputation: 16
How do I echo colors on Slackware boot up?


Hello, all - I seem to stumble more and more into certain "projects" that I need help with or reference to. I'm currently working with Slackware 11 - very speedy compared to the others I've kibbitzed with. However...

When I select the 'Slackware' entry from my GRUB menu, I get nothing but gray letters on a black screen while the system opens up for business. I've decided that it would be easier on me (and my eyes) if I had a way to colorize the boot processes, in something that is somewhat similar to Knoppix's start-up. I've searched, here and on Google, but either I don't yet know what to put in the search terms or what I've found doesn't seem to apply.

What do I need to be looking for or doing to make that happen? And what outputs do I need to post? And if I need to re-compile, what options do I need to select?

Much thanks.
 
Old 12-04-2006, 09:04 AM   #2
bigrigdriver
LQ Addict
 
Registered: Jul 2002
Location: East Centra Illinois, USA
Distribution: Debian Jessie 8.4
Posts: 5,873

Rep: Reputation: 348Reputation: 348Reputation: 348Reputation: 348
The file, in SuSE at any rate, is /etc/rc.status. Here are the opening comments from that file:

Quote:
# /etc/rc.status
# Definition of boot script return messages
#
# The bootscripts should use the variables rc_done and rc_failed to
# report whether they failed or succeeded. See /etc/init.d/skeleton for
# an example how the shell functions rc_status and rc_reset are used.
#
# These functions make use of the variables rc_done and rc_failed;
# rc_done_up and rc_failed_up are the same as rc_done and rc_failed
# but contain a terminal code to move up one line before the output
# of the actual string. (This is particularly useful when the script
# starts a daemon which produces user output with a newline character)
#
# The variable rc_reset is used by the master resource control script
# /etc/init.d/rc to turn off all attributes and switch to the standard
# character set.
#
# \033 ascii ESCape
# \033[<NUM>G move to column <NUM> (linux console, xterm, not vt100)
# \033[<NUM>C move <NUM> columns forward but only upto last column
# \033[<NUM>D move <NUM> columns backward but only upto first column
# \033[<NUM>A move <NUM> rows up
# \033[<NUM>B move <NUM> rows down
# \033[1m switch on bold
# \033[31m switch on red
# \033[32m switch on green
# \033[33m switch on yellow
# \033[m switch off color/bold
# \017 exit alternate mode (xterm, vt100, linux console)
# \033[10m exit alternate mode (linux console)
# \015 carriage return (without newline)
#
 
Old 12-04-2006, 11:15 PM   #3
polarbear20000
Member
 
Registered: Oct 2006
Location: Crestview, FL
Distribution: Slackware 13, Debian 8.1
Posts: 99
Blog Entries: 1

Original Poster
Rep: Reputation: 16
Quote:
Originally Posted by bigrigdriver
The file, in SuSE at any rate, is /etc/rc.status.
Hmmm . . . not to display my ignorance (too much so, I hope) but does Slackware use the same files as SuSE? I understand that different Linuxes might use different ways to go about the same thing, but if I should use this file or something similar, would it work? I only ask since I did not see a file or reference to this specific file in my fruitless search. Would I need to make a link to this or would the system look for it as a matter of course?

Thanks for your help - it gives me a starting point.
 
Old 12-05-2006, 12:19 AM   #4
bigrigdriver
LQ Addict
 
Registered: Jul 2002
Location: East Centra Illinois, USA
Distribution: Debian Jessie 8.4
Posts: 5,873

Rep: Reputation: 348Reputation: 348Reputation: 348Reputation: 348
I guess the first step is to verify that you do/don't have a file called rc.status.

locate rc.status

You may have it, but in a sub-directory of /etc. Or, you may not have it.

The next text would be to search for the escape codes that determine the color output.
'# \033[31m switch on red' contains \033, so let's look for that.

find /etc -type f | xargs grep '\033'

will find every file in /etc containing that sequence. If you include the square bracket [, you will get an error message about unmatched [.

Then look through the files returned for the code sequences I provided earlier. If Slackware has any means of controling the colors, the scrpt should have those color codes, regardless of the name of the script.

Oops, forgot to mention. You may have to run find as root to be able to grep files that user doesn't have permission to view.

Last edited by bigrigdriver; 12-05-2006 at 12:21 AM.
 
Old 12-06-2006, 08:43 PM   #5
polarbear20000
Member
 
Registered: Oct 2006
Location: Crestview, FL
Distribution: Slackware 13, Debian 8.1
Posts: 99
Blog Entries: 1

Original Poster
Rep: Reputation: 16
No luck using any of those suggestions, although I did think that they was good.

What about "DIR_COLORS?" Isn't this what dictates directory listings, but if so, can it be used for startup in some way?
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
ls | echo, I got blank, why can't echo take the 2nd seat in a pipeline? elinuxqs Linux - Newbie 6 11-24-2006 09:25 AM
Echo Indigo IO PCMCIA on Slackware 10.2 Jeiku Linux - Hardware 2 01-12-2006 05:22 AM
Only 256 colors on Slackware 9.1 Quartzophobia Linux - Laptop and Netbook 1 01-27-2004 05:26 PM
slackware 8.1 colors k3v0 Linux - Newbie 6 11-12-2002 02:53 PM
echo off boot up messages skk Linux - General 6 04-12-2002 11:03 AM


All times are GMT -5. The time now is 05:27 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration