Questions tagged [rc]

An RC file is a script file containing startup instructions for an application program (or an entire operating system). These are usually a text file containing commands of the sort that might have been invoked manually once the system was running but are to be executed automatically each time the system starts up.

Filter by
Sorted by
Tagged with
0
votes
1answer
25 views

Does the rc folder contain files that start on boot?

I created a file in /etc/rc0.d, named it rc.local. In this file I added a line that run another file that I had put in Desktop. I did all this so that the command can be run on boot. I followed the ...
1
vote
2answers
600 views

Trouble update-rc.d remove'ing dnsmasq on Debian Stretch

Background: On my Debian Stretch machine at home, I've noticed my DNS lookup times are pretty slow, and have concluded that the culprit is dnsmasq - since if I take it down, name resolution becomes > ...
0
votes
1answer
146 views

Proper way to checkout home directory .rc files from a git repo?

What is the proper way to checkout a bunch of .*rc files into a home directory? I've seen lots of github repos online and people usually name them dotfiles, and I guess they get checked out into ...
0
votes
2answers
44 views

How do I use multiple .zshrcs?

I want to use different zshrcs and choose one using a single file tat holds variables and loads them up. I've tried looking it up, but there are only for iTerm2. I would appreciate any support. Thank ...
1
vote
1answer
962 views

rc.local is not running /sbin/ifconfig command

/etc/rc.local code, echo "rc.local has started successfully" > /home/sk/tmp/init.log isEthConfigured=$(ifconfig eth0 | grep "inet addr") echo "rc.local has run ifconfig command well, with result -...
0
votes
1answer
83 views

Ranger: set default apps for files

I use arch linux, ranger and nvim. When I try to open any text file, ranger does not do anything and this is on output: /bin/sh: line 1: vim: command not found What can i do to open file in neovim ?
0
votes
1answer
44 views

How to run Odoo ERP as daemon on FreeBSD?

I've cloned odoo ERP using git, in directory /home/amr/erp/odoo. Of course I've create a virtual environment and created a startup script "odoo" in /usr/local/etc/rc.d My concern is not to ...
0
votes
0answers
35 views

Where is the environment for boot scripts such as rc.local defined?

I've checked $PATH inside /etc/rc.local and got the following string: /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin Where is this string defined, and what other variables can I expect ...
6
votes
3answers
4k views

How to properly enable httpd with rcctl on OpenBSD so that it starts automatically?

On a OpenBSD machine running OpenBSD 6.2 amd64, httpd cannot be started by using rcctl: # rcctl start httpd httpd(failed) However, when started by just entering httpd, it works; but this is not the ...
0
votes
1answer
67 views

What are the key components of a desktop environment?

I'm a relatively new Linux user. I started with Ubuntu 20.04 a few months ago, and eased myself into the experience, learning a bit of the command line and becoming familiar with the system structure ...
0
votes
0answers
164 views

Using a watchdog timer to prevent hang on reboot

I have a Raspberry Pi running Raspbian GNU/Linux 10 (buster), which has an onboard watchdog timer. I have configured this with a test script that looks for /tmp/force-reboot.txt, and if that file ...
4
votes
3answers
500 views

Is it possible to have conditionals in /etc/rc.local?

Is it possible to have a conditional within /etc/rc.local? I've checked many Q&As and most people suggest running chmod +x on it, but my problem is different. It actually does work for me without ...
1
vote
4answers
2k views

Openbox - multiple commands separated with & for one keypress

I am trying to configure Openbox's rc.xml file in order to manipulate my soundcards with one keypress. Because I have multiple sound cards on my system I have to manipulate multiple sinks at once so I ...
3
votes
1answer
124 views

FreeBSD sysrc to add comments

Is there a way to use FreeBSDs sysrc to add comments to the file that it’s modifying? For example, if I had an /etc/rc.conf with the standard stuff hostname=“FreeBSDMachine” ifconfig_em0=“DHCP” ...
0
votes
3answers
36 views

How does Linux know what function to choose in rcX.d directory?

For example, I have the following script: ... start(){ echo "Starting..." su - $ORA_OWNER -c "$ORA_HOME/bin/dbstart $ORA_HOME" su - $ORA_OWNER -c "$ORA_HOME/bin/emctl start dbconsole" ...
0
votes
0answers
28 views

cupsd not starting at boot in TrueOS

I have installed a TrueOS 13.0-CURRENT desktop system with cups 2.2.8 installed from pkg. Printing works like a charm, but cupsd is not starting at boot, despite this being in /etc/rc.conf: ...
2
votes
1answer
763 views

.bashrc or .profile for busybox on windows

I have enough experience with scripting on *nix servers, but busybox on Windows I enjoy first. I installed busybox using scoop. When I run: ash echo $HOME I got -> C:/Users/RO # OK, this is dir ...
3
votes
1answer
3k views

Automatically start an application with a modifed LD_PRELOAD?

I have an application that needs a modified LD_PRELOAD. I want to start the application using the originally provided rc script, so I can benefit from an automatically updated rc script on an update ...
0
votes
0answers
121 views

execute script on startup without rc-update

I want to execute a script that sets iptable rules on each startup. I read about the option to write a *.start script to /etc/local.d here, but I cannot execute rc-update add local default to add ...
1
vote
1answer
501 views

Add an SSH key on boot

I have a Git repo that is authenticated with an SSH key - the key is not the standard id_rsa. I can run: eval $(ssh-agent -s) ssh-add /home/forge/.ssh/otherkey Then git pull origin master This ...
2
votes
0answers
50 views

Is there something like rc.local in systemd? [duplicate]

Back with system V init there was a script called rc.local where you could stuff commands that needed to be run during bootup, which would not fit to one particular service. Does systemd have a ...
0
votes
0answers
88 views

Why do the shutdown and startup scripts placed at /etc/init.d/ not run on shutting down or during startup?

I basically have a simple script #!/bin/sh sudo echo "process kill" >> /home/logfile placed at etc/init.d/lokill and symbolic links K99lokill to /etc/init.d/lokill placed at /etc/rc0.d and /...
0
votes
1answer
75 views

Why do all the links in /etc/rc6.d start with K if runlevel 6 corresponds to reboot?

I was trying to find out how to run a script at startup and during shutdown during which I got to know that level 6 corresponds to reboot in ubuntu. When I opened the /etc/rc6.d every link's name ...
3
votes
2answers
10k views

What is the difference between rc, rc.local and rc.sysinit?

I tried to display the list of startup scripts for the current runlevel at bootup. I wrote the following code. rl=`runlevel | cut -d " " -f2` ls /etc/rc.d/rc$rl.d/S* | cut -d "/" -f5 sleep 10 It's ...
3
votes
2answers
12k views

Why is rcS required after file system is mounted by the kernel?

I using embedded Linux, I have compiled the kernel without initramfs and kernel is booting fine. But It shows me rcS file is not found I have put it in /etc/init.d/rcS and my rcS file look like #!/...
1
vote
1answer
1k views

How to automatically start Rescuetime on startup (tried crontab and rc.local)

I have installed rescuetime on debian 9. It requires the command rescuetime to be run in a terminal, this just keeps running rather than running and closing (it adds an icon into the tray at the ...
2
votes
0answers
45 views

Run interactive script before reboot

CentOS VM. I got a script for updating firmware that I would like to run before each reboot. However, I want to get user confirmation before the script is actually run. I put the script in /etc/init....
0
votes
2answers
2k views

Execute simple script before shutdown and reboot

I need to run a script before shutting down or rebooting my VPS running Debian 8,to keep count of network statistics.I tried adding the script directly to /etc/init.d and symlinking it in /etc/rc0.d ...
1
vote
1answer
160 views

rc scripts for multiple Zope instances in FreeBSD

I'm trying to configure multiple Zope-Instances as daemons in FreeBSD. Each instance gets a start script in /usr/local/etc/rc.d. Starting works fine, but invoking status or stop is problematic because ...
0
votes
0answers
125 views

/etc/init.d and /etc/rcX.d/: how do they work with systemd

I've known that Debian and Ubuntu have used systemd to manage the services running at boot time. I've known that there were /etc/rcX.d/ and /etc/init.d/, which are also about services running at boot ...
2
votes
1answer
7k views

Windows Subsystem for Linux is unable to determine current runlevel

Issue Many apt-get installs are failing b/c the system can't determine current runlevel Background specs: $ lsb_release -a No LSB modules are available. Distributor ID: Ubuntu Description: Ubuntu ...
2
votes
1answer
390 views

IPV6 aliases in rc.conf

I am currently running FreeBSD 12.0-RELEASE-p2, and I can't figure out how to create both IPV4 and IPV6 aliases for a loopback (lo1) interface using rc.conf on boot. Here is a snippet of my rc.conf: ...
0
votes
1answer
147 views

What is the best way for storing and versioning his aliases/functions/symlinks?

actually I have these lines (exemplary) in my .zshrc file: . ${TOOLS_HOME}/cli/.cli_base . ${TOOLS_HOME}/cli/.cli_functions . ${TOOLS_HOME}/cli/.cli_symlinks This works fine so far. My only problem ...
4
votes
1answer
2k views

Cannot trigger tmux script on boot

I have a tmux triggering script as mentioned below, running on Raspbian Wheezy 7.10: Step 1 #!/bin/bash # this script is called "sess" tmux new-session -d -s sess1 'sudo /home/pi/bin/myscript.py' ...
3
votes
1answer
3k views

My .vimrc file disabled the copy/paste action using mouse right click!

Am using an open source .vimrc file from GitHub, but it is screwing up my default mouse right click, copy-paste actions. Whenever I do a right click, it enters into the visual mode and I am having a ...
0
votes
2answers
612 views

ifconfig not displaying NIC's and also no wired Ethernet connection

After rebooting, my network interface card (renamed from eth0 to enp0s25) is not displayed with the command ifconfig, only in ifconfig -a. Also ping -c 4 google.com only yields unknown host. In my /...
1
vote
1answer
694 views

How to add an alias IP to a VLAN interface in FreeBSD

How can I add an alias to a VLAN interface in FreeBSD? I tried the following, but it seems to be ignored: # /etc/rc.conf vlans_igb0="vlan42" create_args_vlan42="vlan 42" ifconfig_igb0="up" ...
1
vote
1answer
339 views

Running and managing two daemons with same executable by rc together

I use FreeBSD UNIX and its rc system of startup scripts to make my Node.js servers start at reboot as a daemon and start, as a daemon again, and stop them with some commands the system gives me after ...
2
votes
0answers
455 views

Debian Wheezy : problem installing .deb package that uses update-rc.d with dependency numbers

I'm trying to install a .deb file, written by us, on a new Debian Wheezy system. The .deb file was originally written for Lenny, so is fairly old. I've tracked down one point where the installation ...
5
votes
2answers
2k views

How can I customize $PROMPT_COMMAND without overwriting the default (if present)?

Mac's Terminal comes with a default PROMPT_COMMAND that checks the history and updates the current working directory (title of the tab): Add echo $PROMPT_COMMAND to the top of your .bash_profile and ...
0
votes
1answer
4k views

systemd[1]: Failed to start /etc/rc.local Compatibility

I'm using Raspbian on a Raspberry Pi, and I see this error when booting up the system: Nov 25 20:30:38 raspberrypi systemd[1]: rc-local.service: control process exited, code=exited status=127 Nov 25 ...
0
votes
0answers
67 views

'Chain' shells' profile and runcom files?

While setting zsh up, I found a post stating that to keep a .zshrc as clean and backwards compatible as possible, one can 'chain' the shells' configuration files. If I recall, it consists more or less ...
1
vote
2answers
1k views

Color syntax highlighting working on one system but not the others. Same nanorc file

I'm trying to set my color syntax highlighting in nano, but it doesn't work as expected. One system everything works. This is an Fedora 21 laptop. Two systems everything I've tried except man ...
-3
votes
1answer
821 views

Fixing RC4 cipher suites [closed]

I've conducted an AppScan on my web application, and it determined that the site uses weak cipher suites, as the AppScan successfully created SSL connections using each of the weak cipher suites ...
0
votes
1answer
2k views

boot normally even with an infinite loop in /etc/rc.local

I put a python script with an infinite loop into /etc/rc.local but the machine boots successfully, which confuses me. The /etc/rc.local content: #!/bin/sh -e # # rc.local # # This script is executed ...
0
votes
1answer
805 views

FreeBSD 7.3: service is working, but status shows “is not running”

Something wrong with one service on FreeBSD 7.3: 1) it starts with command "service my_secret_service start" but later if I enter "service my_secret_service status" - it shows as not running. But in ...
6
votes
1answer
6k views

zsh: is there a problem with always enabling extended glob?

I recetnly came across setopt extended_glob ...in order to enable extended globbing which allows for a number of cool wildcard additions, like excluding specific patterns, for example: ls ^foo* ......
0
votes
2answers
1k views

New MySQL Installation on pfSense returns 'Bad -c option' when started

this is my first time actually using FreeBSD so there's a chance I might have missed something big, but it's unlikely. So I want to set up mysql on my pfSense server so I can enable historical ...
0
votes
1answer
243 views

Does rc.local crash?

I am using rc.local to run a python script on boot up on a raspberry pi and it almost always runs without an issue but on occasion, it seems like it might be crashing. Can a script run in rc.local ...
2
votes
1answer
138 views

Is there any database solution that can do master-master replication by default on OpenBSD?

There are many "built-in" softwares for OpenBSD, ex.: NTP, LDAP, RADIUS, etc., see all (?): https://github.com/openbsd/src/blob/master/etc/rc.conf in the rc.conf file. The question: Currently, ...