Jump to content
Search In
  • More options...
Find results that contain...
Find results in...

I want to make a startup script for my servers running arch linux

I would like to make a startup script that does these things:

1. auto login

2. starts the GUI(LXDE)

3. opens all the terminal tabs I need

4. starts my vnc (tigervnc) in one of those terminals

5. starts my minecraft servers in those terminals

6. maybe auto update?

7. moves all the tabs to the position that I need them in.

Link to post
Share on other sites
40 minutes ago, Lemon797 said:

1. auto login

2. starts the GUI(LXDE)

https://wiki.archlinux.org/index.php/LightDM#Enabling_autologin

41 minutes ago, Lemon797 said:

3. opens all the terminal tabs I need

4. starts my vnc (tigervnc) in one of those terminals

5. starts my minecraft servers in those terminals

https://wiki.archlinux.org/index.php/Xprofile

 

depending on which terminal you use the command to run a program upon opening it will be different.

 

Also vnc and your minecraft server can be made into systemd services, which is a much cleaner way of doing this.

41 minutes ago, Lemon797 said:

6. maybe auto update?

Bad idea on Arch, some updates require manual intervention.

 

43 minutes ago, Lemon797 said:

7. moves all the tabs to the position that I need them in.

Not sure you can do that

Don't ask to ask, just ask... please 🤨

sudo chmod -R 000 /*

What is scaling and how does it work? Asus PB287Q unboxing! Console alternatives :D Watch Netflix with Kodi on Arch Linux Sharing folders over the internet using SSH Beginner's Guide To LTT (by iamdarkyoshi)

Sauron'stm Product Scores:

Spoiler

Just a list of my personal scores for some products, in no particular order, with brief comments. I just got the idea to do them so they aren't many for now :)

Don't take these as complete reviews or final truths - they are just my personal impressions on products I may or may not have used, summed up in a couple of sentences and a rough score. All scores take into account the unit's price and time of release, heavily so, therefore don't expect absolute performance to be reflected here.

 

-Lenovo Thinkpad X220 - [8/10]

Spoiler

A durable and reliable machine that is relatively lightweight, has all the hardware it needs to never feel sluggish and has a great IPS matte screen. Downsides are mostly due to its age, most notably the screen resolution of 1366x768 and usb 2.0 ports.

 

-Apple Macbook (2015) - [Garbage -/10]

Spoiler

From my perspective, this product has no redeeming factors given its price and the competition. It is underpowered, overpriced, impractical due to its single port and is made redundant even by Apple's own iPad pro line.

 

-OnePlus X - [7/10]

Spoiler

A good phone for the price. It does everything I (and most people) need without being sluggish and has no particularly bad flaws. The lack of recent software updates and relatively barebones feature kit (most notably the lack of 5GHz wifi, biometric sensors and backlight for the capacitive buttons) prevent it from being exceptional.

 

-Microsoft Surface Book 2 - [Garbage - -/10]

Spoiler

Overpriced and rushed, offers nothing notable compared to the competition, doesn't come with an adequate charger despite the premium price. Worse than the Macbook for not even offering the small plus sides of having macOS. Buy a Razer Blade if you want high performance in a (relatively) light package.

 

-Intel Core i7 2600/k - [9/10]

Spoiler

Quite possibly Intel's best product launch ever. It had all the bleeding edge features of the time, it came with a very significant performance improvement over its predecessor and it had a soldered heatspreader, allowing for efficient cooling and great overclocking. Even the "locked" version could be overclocked through the multiplier within (quite reasonable) limits.

 

-Apple iPad Pro - [5/10]

Spoiler

A pretty good product, sunk by its price (plus the extra cost of the physical keyboard and the pencil). Buy it if you don't mind the Apple tax and are looking for a very light office machine with an excellent digitizer. Particularly good for rich students. Bad for cheap tinkerers like myself.

 

 

Link to post
Share on other sites
Quote

ok I will look at that.

Quote

https://wiki.archlinux.org/index.php/Xprofile

 

depending on which terminal you use the command to run a program upon opening it will be different.

I use the LXTerminal witch I can just use the LTXerminal command to run.

Quote

Also vnc and your minecraft server can be made into systemd services, which is a much cleaner way of doing this.

Could you explain how to do this, and if I did would the terminal tabs open for them so I could monitor them?

Quote

Bad idea on Arch, some updates require manual intervention.

Ok.

Quote

Not sure you can do that

Ok. I was hopeing I could because it's a lot easier to monitor everything that way.

@Sauron

Link to post
Share on other sites
12 minutes ago, Sauron said:

Bad idea on Arch, some updates require manual intervention.

Also a bad idea because Arch (or, at the very least, some random package/dependency you need) loves to break itself when you upgrade.

Quote me to see my reply!

SPECS:

CPU: Xeon X5650 OC'd to 4.2GHz @ 1.35V (courtesy of @XR6)Motherboard: Asus Sabertooth X58 RAM: 4x4GB G.Skill DDR3 1866MHz GPU: Asus RX 570 Strix Storage: WD Blue 1TB and a 128GB Kingston UV400 PSU: EVGA 600B Case: Fractal Design Define C Cooling: H100i V2, be quiet! Pure Wings 2 (two intake, two exhausting through radiator) Monitor: 3x Dell P2210 on a Steelcase Eyesite triple monitor stand Mouse: Logitech G403 Prodigy Wireless Keyboard: It changes, but usually Focus FK-9000 Mousepad: Steelseries QcK XL Headphones:  Sennheiser HD598SE

 

 

 

 

i use arch btw

Link to post
Share on other sites
15 minutes ago, kelvinhall05 said:

Also a bad idea because Arch (or, at the very least, some random package/dependency you need) loves to break itself when you upgrade.

ok. how can I make the minecraft server and vnc into systemd services?

Link to post
Share on other sites
Just now, Lemon797 said:

ok. how can I make the minecraft server and vnc into systemd services?

Not sure about VNC, but for the MC server you can make a systemd service that just runs a bash script that starts the server. There are tons of guides on how to do that online.

Quote me to see my reply!

SPECS:

CPU: Xeon X5650 OC'd to 4.2GHz @ 1.35V (courtesy of @XR6)Motherboard: Asus Sabertooth X58 RAM: 4x4GB G.Skill DDR3 1866MHz GPU: Asus RX 570 Strix Storage: WD Blue 1TB and a 128GB Kingston UV400 PSU: EVGA 600B Case: Fractal Design Define C Cooling: H100i V2, be quiet! Pure Wings 2 (two intake, two exhausting through radiator) Monitor: 3x Dell P2210 on a Steelcase Eyesite triple monitor stand Mouse: Logitech G403 Prodigy Wireless Keyboard: It changes, but usually Focus FK-9000 Mousepad: Steelseries QcK XL Headphones:  Sennheiser HD598SE

 

 

 

 

i use arch btw

Link to post
Share on other sites
Just now, kelvinhall05 said:

Not sure about VNC, but for the MC server you can make a systemd service that just runs a bash script that starts the server. There are tons of guides on how to do that online.

ok. will the mc servers gui boot up if I make the mc server a systemd service?

Link to post
Share on other sites
1 minute ago, Lemon797 said:

ok. will the mc servers gui boot up if I make the mc server a systemd service?

GUI? Both the official vanilla MC server from Mojang and Paper (what you should be using tbh) are interacted with through CLI.

Quote me to see my reply!

SPECS:

CPU: Xeon X5650 OC'd to 4.2GHz @ 1.35V (courtesy of @XR6)Motherboard: Asus Sabertooth X58 RAM: 4x4GB G.Skill DDR3 1866MHz GPU: Asus RX 570 Strix Storage: WD Blue 1TB and a 128GB Kingston UV400 PSU: EVGA 600B Case: Fractal Design Define C Cooling: H100i V2, be quiet! Pure Wings 2 (two intake, two exhausting through radiator) Monitor: 3x Dell P2210 on a Steelcase Eyesite triple monitor stand Mouse: Logitech G403 Prodigy Wireless Keyboard: It changes, but usually Focus FK-9000 Mousepad: Steelseries QcK XL Headphones:  Sennheiser HD598SE

 

 

 

 

i use arch btw

Link to post
Share on other sites
Just now, kelvinhall05 said:

GUI? Both the official vanilla MC server from Mojang and Paper (what you should be using tbh) are interacted with through CLI.

yes i know and I am using paper, but I mean the Minecraft server java gui.

Link to post
Share on other sites
Just now, Lemon797 said:

yes i know and I am using paper, but I mean the Minecraft server java gui.

I still have no idea what you're talking about, and why do you need a GUI?

Quote me to see my reply!

SPECS:

CPU: Xeon X5650 OC'd to 4.2GHz @ 1.35V (courtesy of @XR6)Motherboard: Asus Sabertooth X58 RAM: 4x4GB G.Skill DDR3 1866MHz GPU: Asus RX 570 Strix Storage: WD Blue 1TB and a 128GB Kingston UV400 PSU: EVGA 600B Case: Fractal Design Define C Cooling: H100i V2, be quiet! Pure Wings 2 (two intake, two exhausting through radiator) Monitor: 3x Dell P2210 on a Steelcase Eyesite triple monitor stand Mouse: Logitech G403 Prodigy Wireless Keyboard: It changes, but usually Focus FK-9000 Mousepad: Steelseries QcK XL Headphones:  Sennheiser HD598SE

 

 

 

 

i use arch btw

Link to post
Share on other sites
Just now, kelvinhall05 said:

I still have no idea what you're talking about, and why do you need a GUI?

How to Run a Simple Local Minecraft Server (With and Without Mods)

This is what I mean. and I use it to run the commands.

Link to post
Share on other sites
1 minute ago, Lemon797 said:

How to Run a Simple Local Minecraft Server (With and Without Mods)

This is what I mean. and I use it to run the commands.

You can view all that information and run commands from the cli interface...

Quote me to see my reply!

SPECS:

CPU: Xeon X5650 OC'd to 4.2GHz @ 1.35V (courtesy of @XR6)Motherboard: Asus Sabertooth X58 RAM: 4x4GB G.Skill DDR3 1866MHz GPU: Asus RX 570 Strix Storage: WD Blue 1TB and a 128GB Kingston UV400 PSU: EVGA 600B Case: Fractal Design Define C Cooling: H100i V2, be quiet! Pure Wings 2 (two intake, two exhausting through radiator) Monitor: 3x Dell P2210 on a Steelcase Eyesite triple monitor stand Mouse: Logitech G403 Prodigy Wireless Keyboard: It changes, but usually Focus FK-9000 Mousepad: Steelseries QcK XL Headphones:  Sennheiser HD598SE

 

 

 

 

i use arch btw

Link to post
Share on other sites
Just now, kelvinhall05 said:

You can view all that information and run commands from the cli interface...

I know but will the cli launch?

Link to post
Share on other sites
2 minutes ago, Lemon797 said:

I know but will the cli launch?

You can have the script open a screen for minecraft and run it in there, and then you can just connect to that screen whenever you need to do something on the server.

Quote me to see my reply!

SPECS:

CPU: Xeon X5650 OC'd to 4.2GHz @ 1.35V (courtesy of @XR6)Motherboard: Asus Sabertooth X58 RAM: 4x4GB G.Skill DDR3 1866MHz GPU: Asus RX 570 Strix Storage: WD Blue 1TB and a 128GB Kingston UV400 PSU: EVGA 600B Case: Fractal Design Define C Cooling: H100i V2, be quiet! Pure Wings 2 (two intake, two exhausting through radiator) Monitor: 3x Dell P2210 on a Steelcase Eyesite triple monitor stand Mouse: Logitech G403 Prodigy Wireless Keyboard: It changes, but usually Focus FK-9000 Mousepad: Steelseries QcK XL Headphones:  Sennheiser HD598SE

 

 

 

 

i use arch btw

Link to post
Share on other sites
Just now, kelvinhall05 said:

You can have the script open a screen for minecraft and run it in there, and then you can just connect to that screen whenever you need to do something on the server.

Is there a way to have it launch in a terminal on the main screen?

Link to post
Share on other sites
3 minutes ago, Lemon797 said:

Is there a way to have it launch in a terminal on the main screen?

Yes, just have the script open whatever terminal emulator you want.

Quote me to see my reply!

SPECS:

CPU: Xeon X5650 OC'd to 4.2GHz @ 1.35V (courtesy of @XR6)Motherboard: Asus Sabertooth X58 RAM: 4x4GB G.Skill DDR3 1866MHz GPU: Asus RX 570 Strix Storage: WD Blue 1TB and a 128GB Kingston UV400 PSU: EVGA 600B Case: Fractal Design Define C Cooling: H100i V2, be quiet! Pure Wings 2 (two intake, two exhausting through radiator) Monitor: 3x Dell P2210 on a Steelcase Eyesite triple monitor stand Mouse: Logitech G403 Prodigy Wireless Keyboard: It changes, but usually Focus FK-9000 Mousepad: Steelseries QcK XL Headphones:  Sennheiser HD598SE

 

 

 

 

i use arch btw

Link to post
Share on other sites

@Lemon797 By "screen" I don't mean a physical display.

https://linux.die.net/man/1/screen

Quote me to see my reply!

SPECS:

CPU: Xeon X5650 OC'd to 4.2GHz @ 1.35V (courtesy of @XR6)Motherboard: Asus Sabertooth X58 RAM: 4x4GB G.Skill DDR3 1866MHz GPU: Asus RX 570 Strix Storage: WD Blue 1TB and a 128GB Kingston UV400 PSU: EVGA 600B Case: Fractal Design Define C Cooling: H100i V2, be quiet! Pure Wings 2 (two intake, two exhausting through radiator) Monitor: 3x Dell P2210 on a Steelcase Eyesite triple monitor stand Mouse: Logitech G403 Prodigy Wireless Keyboard: It changes, but usually Focus FK-9000 Mousepad: Steelseries QcK XL Headphones:  Sennheiser HD598SE

 

 

 

 

i use arch btw

Link to post
Share on other sites
8 minutes ago, kelvinhall05 said:

Yes, just have the script open whatever terminal emulator you want.

So if I made a script that says lxterminal -e bash -c "cd /dir/to/server" -e bash -c "./update.sh"

(update.sh is the script the updates and runs the mc server)

Link to post
Share on other sites
26 minutes ago, Lemon797 said:

ok. how can I make the minecraft server and vnc into systemd services?

Read the wiki...

https://wiki.archlinux.org/index.php/TigerVNC#Starting_and_stopping_x0vncserver_via_systemd

https://wiki.archlinux.org/index.php/Minecraft#Starting_the_server_2

Don't ask to ask, just ask... please 🤨

sudo chmod -R 000 /*

What is scaling and how does it work? Asus PB287Q unboxing! Console alternatives :D Watch Netflix with Kodi on Arch Linux Sharing folders over the internet using SSH Beginner's Guide To LTT (by iamdarkyoshi)

Sauron'stm Product Scores:

Spoiler

Just a list of my personal scores for some products, in no particular order, with brief comments. I just got the idea to do them so they aren't many for now :)

Don't take these as complete reviews or final truths - they are just my personal impressions on products I may or may not have used, summed up in a couple of sentences and a rough score. All scores take into account the unit's price and time of release, heavily so, therefore don't expect absolute performance to be reflected here.

 

-Lenovo Thinkpad X220 - [8/10]

Spoiler

A durable and reliable machine that is relatively lightweight, has all the hardware it needs to never feel sluggish and has a great IPS matte screen. Downsides are mostly due to its age, most notably the screen resolution of 1366x768 and usb 2.0 ports.

 

-Apple Macbook (2015) - [Garbage -/10]

Spoiler

From my perspective, this product has no redeeming factors given its price and the competition. It is underpowered, overpriced, impractical due to its single port and is made redundant even by Apple's own iPad pro line.

 

-OnePlus X - [7/10]

Spoiler

A good phone for the price. It does everything I (and most people) need without being sluggish and has no particularly bad flaws. The lack of recent software updates and relatively barebones feature kit (most notably the lack of 5GHz wifi, biometric sensors and backlight for the capacitive buttons) prevent it from being exceptional.

 

-Microsoft Surface Book 2 - [Garbage - -/10]

Spoiler

Overpriced and rushed, offers nothing notable compared to the competition, doesn't come with an adequate charger despite the premium price. Worse than the Macbook for not even offering the small plus sides of having macOS. Buy a Razer Blade if you want high performance in a (relatively) light package.

 

-Intel Core i7 2600/k - [9/10]

Spoiler

Quite possibly Intel's best product launch ever. It had all the bleeding edge features of the time, it came with a very significant performance improvement over its predecessor and it had a soldered heatspreader, allowing for efficient cooling and great overclocking. Even the "locked" version could be overclocked through the multiplier within (quite reasonable) limits.

 

-Apple iPad Pro - [5/10]

Spoiler

A pretty good product, sunk by its price (plus the extra cost of the physical keyboard and the pencil). Buy it if you don't mind the Apple tax and are looking for a very light office machine with an excellent digitizer. Particularly good for rich students. Bad for cheap tinkerers like myself.

 

 

Link to post
Share on other sites
1 minute ago, Lemon797 said:

So if I made a script that says lxterminal -e bash -c "cd /dir/to/server" -e bash -c "./update.sh"

(update.sh is the script the updates and runs the mc server)

Where do I put the file and what type of file is it?

Link to post
Share on other sites
1 minute ago, Lemon797 said:

So if I made a script that says lxterminal -e bash -c "cd /dir/to/server" -e bash -c "./update.sh"

 

(update.sh is the script the updates and runs the mc server)

Why all those arguements? iirc you should be able to just run

lxterminal -e /path/to/update.sh

 

Quote me to see my reply!

SPECS:

CPU: Xeon X5650 OC'd to 4.2GHz @ 1.35V (courtesy of @XR6)Motherboard: Asus Sabertooth X58 RAM: 4x4GB G.Skill DDR3 1866MHz GPU: Asus RX 570 Strix Storage: WD Blue 1TB and a 128GB Kingston UV400 PSU: EVGA 600B Case: Fractal Design Define C Cooling: H100i V2, be quiet! Pure Wings 2 (two intake, two exhausting through radiator) Monitor: 3x Dell P2210 on a Steelcase Eyesite triple monitor stand Mouse: Logitech G403 Prodigy Wireless Keyboard: It changes, but usually Focus FK-9000 Mousepad: Steelseries QcK XL Headphones:  Sennheiser HD598SE

 

 

 

 

i use arch btw

Link to post
Share on other sites
Just now, kelvinhall05 said:

Why all those arguements? iirc you should be able to just run


lxterminal -e /path/to/update.sh

 

ok.

Link to post
Share on other sites
2 minutes ago, Sauron said:

OP is running a Paper server which iirc does not create a systemd service when run for the first time. It has to be started and run with java.

Quote me to see my reply!

SPECS:

CPU: Xeon X5650 OC'd to 4.2GHz @ 1.35V (courtesy of @XR6)Motherboard: Asus Sabertooth X58 RAM: 4x4GB G.Skill DDR3 1866MHz GPU: Asus RX 570 Strix Storage: WD Blue 1TB and a 128GB Kingston UV400 PSU: EVGA 600B Case: Fractal Design Define C Cooling: H100i V2, be quiet! Pure Wings 2 (two intake, two exhausting through radiator) Monitor: 3x Dell P2210 on a Steelcase Eyesite triple monitor stand Mouse: Logitech G403 Prodigy Wireless Keyboard: It changes, but usually Focus FK-9000 Mousepad: Steelseries QcK XL Headphones:  Sennheiser HD598SE

 

 

 

 

i use arch btw

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×