Questions tagged [startupscript]
158 questions
-1
votes
2 answers
How to create a folder in home directory(ubuntu16.04) using GCP start up script at time of GCP VM creation?
Here is what I am doing:
gcloud compute instances create example-instance \ --image-family $image \ --image-project $projectID \ --machine-type $type_machine \ --metadata startup-script='#!/bin/bash mkdir -p ~/test'
This look super simple. The…

learning
- 41
- 3
-1
votes
1 answer
How to run 2 tmux sessions on gcp startup?
I was having some trouble when trying to run 2 tmux sessions on startup and I can not for the life of me figure out the problem. To run 1 tmux session I use the following code:
sudo -H -u USERNAME tmux new-session -d -s session1 'python3…

SebastiaanTheCoder
- 33
- 9
-1
votes
1 answer
Where can I find a screen (terminal multiplexer) that was created and detached with a startup-script? (GCP)
I am using GCP to run a game server and added a startup script to the VM to automatically run the gameserver in a screen, so if needed I can access the console to the server by re-attaching, the screen is starting and I am able to connect to the…

asterisk
- 1
- 1
-1
votes
1 answer
Won't boot because of rc.local start up script
Environment :
Virtualization software : VMware Workstation 12 Player
Guest Machine : Red Hat 6.4
Host Machine : Windows 7 Professional Service Pack 1
Question :
I'm trying to execute automatically a svn update at the boot of my virtual machine. I…

Chaton
- 43
- 1
- 8
-1
votes
2 answers
How do I make this Linux script
Ok so I have saved it as test.sh and chmod +x the script.
nmcli con up id myvpn=
/opt/google/chrome/google-chrome %U
geany /home/crunch/downloads/lr.txt
I execute it using terminal however it only connects to the vpn and runs chrome, Geany only…

user2416214
- 1
- 2
-2
votes
0 answers
Automating an 'fn + space' keystroke on startup
I just got a new Lenovo Thinkpad E14 Gen 3, and my OCD wants the backlit keyboard on all the time. There is NO setting to keep the light on at all times (not even in the BIOS), and the keystroke to turn it on is 'Fn + Space'.
At first, I thought I'd…

Seth Bowers
- 31
- 1
- 6
-2
votes
1 answer
Error restarting service: Failed to try-restart nscd.service: Unit nscd.service not found
I am trying to add a startup script in my GCP VM Instance to fetch data from a website (web crawler). I wanted to automate the crawling task following this answer. So, I added a startup script in my VM instance. The script looks like below:
#!…

sksoumik
- 845
- 1
- 9
- 23
-4
votes
1 answer
ssh to Ubuntu Server, run some commands, and then leave myself the default prompt?
As discussed here, we can SSH remote to Ubuntu Server instance, and run command, and open a prompt
ssh -t host 'cmd1; cmd2; sh -i'
Though the shell prompt I get on my Ubuntu Server is not the default one i.e. as I try to run ~ ./bashrc, I get the…

Nam G VU
- 33,193
- 69
- 233
- 372