Fedora startup script help

 
Thread Tools Search this Thread
Operating Systems Linux Red Hat Fedora startup script help
# 1  
Old 06-21-2011
Fedora startup script help

Can someone please tell me how to run a fedora startup script? I read these guides and tried to do what they said with no luck.

Create a Startup Script
[Fedora] Custom Startup Script | Open Source Club at Ohio State University

This is what I put in my startup script.

Code:
#!/bin/bash
# chkconfig: 345 85 15 (however on this one I've seen different combos)

xrandr --output VGA1 --mode 1024x768 --rate 60

# 2  
Old 06-21-2011
What version of Fedora are you using?
# 3  
Old 06-22-2011
Quote:
Originally Posted by fpmurphy
What version of Fedora are you using?
15
# 4  
Old 06-23-2011
Latest versions of Fedora use Upstart instead if init scripts (although it claims to be 100% backwards compatible).

You just have to save your scripts under /etc/init. Here's a simple script:

Code:
description "some nice description here"
start on startup
exec /usr/bin/xrandr --output VGA1 --mode 1024x768 --rate 60 # It's recommended to use absolute paths

Or you could still use "old" /etc/init.d scripts.
# 5  
Old 06-23-2011
I should also note that just being on the same machine as an X server doesn't authorize you to run xrandr on it, you generally have to be logged in or otherwise authorized against the X11 server to use it or alter its settings etc.

Try switching to a raw text console with ctrl-alt-f1 and logging in as root. (ctrl-alt-f7 or f8 should bring you back to the GUI. f2-f6 are different, separate text consoles.) If your xrandr command doesn't work from there, it probably won't work in a boot script.
# 6  
Old 06-29-2011
Hello Sir
Please, help me regarding mail receive issue. My mail server is working fine but one mail id not receiving mail from last 10 days. but sending is okay. What is the problem ?
# 7  
Old 06-29-2011
Please open a new thread. Dont post in the existing (others thread)
Login or Register to Ask a Question

Previous Thread | Next Thread

9 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Startup script

I can't quite find a clear answer on how to properly write a start up script. Does anybody have any ideas?? (3 Replies)
Discussion started by: Huitzilopochtli
3 Replies

2. Fedora

Xrandr on startup - Fedora 19, VMWare Fusion

I've tried following multiple procedures from various sites but can't seem to get this figured out. There was another thread on here about the same thing but I couldn't figure out how to apply it to my situation. This is my first time on Linux so I'm just learning. I am running Fedora 19,... (1 Reply)
Discussion started by: jaykayen
1 Replies

3. Shell Programming and Scripting

Apache tomcat startup script not booting at startup.

I copied the script from an AskUbuntu post - #!/bin/bash ### BEGIN INIT INFO # Provides: tomcat7 # Required-Start: $network # Required-Stop: $network # Default-Start: 2 3 4 5 # Default-Stop: 0 1 6 # Short-Description: Start/Stop Tomcat server ### END INIT INFO ... (14 Replies)
Discussion started by: Hijanoqu
14 Replies

4. AIX

startup script

Hi I need the below script to be started whenever I reboot my aix server ? #cat cdbegin /cdirect/cdunix/ndm/bin/cdpmgr -i /cdirect/cdunix/ndm/cfg/cbspsdb01/initparm.cfg Please suggest how to add this to the startup ? (2 Replies)
Discussion started by: samsungsamsung
2 Replies

5. UNIX for Dummies Questions & Answers

Startup Script Somewhere ?

Hello there! I need help. Everytime I login to my ssh, i see this: -bash: .export: command not found -bash: .export: command not found -bash: .export: command not found -bash: .export: command not found any help ? thanks (0 Replies)
Discussion started by: fbauto1
0 Replies

6. Shell Programming and Scripting

Need to run script at startup.

Hi guys , I Need to run a specific command (pinging a particular machine). Which need to run every time i reboot the server till the time it shut down. What is the preferred way of doing this. Will it impact my system performance. My Operating system is as below. # lsb_release -a... (3 Replies)
Discussion started by: pinga123
3 Replies

7. HP-UX

Executing a script at startup

Hi, I want a script to execute as soon as a user logs in(instead of directing to his home directory). i know that i have to mention the path of script in the user's .profile to execute this, but not sure where and what to edit. I just tried and was unsuccesful. Kindly provide the code that i... (4 Replies)
Discussion started by: sridharr83
4 Replies

8. Shell Programming and Scripting

[Help] startup script on solaris 8

hi experts, i have some problem with my solaris 8 v890 server, is : the server running process called SS7 below is example process : PID STAT MODE HOST MUX OBJECT 384 ok LX|A USSDGmdn-1a spm/0 daemon 385 ok LX|A USSDGmdn-1a spm/2 ... (0 Replies)
Discussion started by: bucci
0 Replies

9. Shell Programming and Scripting

Startup script

New in Unix, I am adding a line "route add 57.14.y.y 57.14.x.x" every day after rebooting the system. Where can I add the line so during boot up (the system is re-started every day by design (???) the line is executed? (I tried the /etc/rc2.d/S90 but for some reason the line needs to be added... (2 Replies)
Discussion started by: texaspanama
2 Replies
Login or Register to Ask a Question