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

Issue with Ubuntu 19.10 Server

3 minutes ago, Nolanrulesroblox said:

The commands that are not working are printF and read

It's not printF, it's printf. Pay more attention to what you write. Also, printf is provided by the package coreutils, ie. apt -y install coreutils on your server. You can also add the following to your script to check for existence of printf and to install it, if it's missing:
 

which printf >/dev/null
if [ $? -eq 1 ]
then
	apt -y install coreutils
fi

 

Recommended Posts

Posted · Original PosterOP

I wrote a Script to Install Apache2, PHP and a few other thins and it doesnt seem to work on the Server version of Ubuntu, but it works fine on Desktop

 

Issues:

Printf (not working)

and

Read (press enter to Continue) 

 

My Script https://github.com/Nolanrulesroblox/Apache2-Install-V2

 

 


PC#1 Ryzen 7 2700x GTX 1080ti 64gb GSKILL 3000mhz samsung 970 evo 1tb m.2 SSD Seagate 10tb 7200rpm HDD EVGA T2 1000W FM,80+T

PC#2 Intel i5 4200u intel HD 4400 8gb DDR3 1600 240 kingston SSD (rip laptop 2015-2018)

PC#3 Razer Blade 15 Base (i7 8750h GTX 1060 MaxQ 32gb ddr4 2400 970 evo 1tb seagate 2tb 7200 rpm HDD)

 

Servers:

Super Micro lga 775 Motherboard x5355 16gb ddr2 ECC 250gb hdd 650w psu

(MAIN server) x2 X5660 128gb DDR3 ECC, 240gb inland SSD, Samsung 850 evo 250gb, 6tb Raid 10 (SAS) x2 870W PSUs 

 

Please, take everything I say with a grain of salt. I'm not a professional, just a moderately knowledgeable nerd.

Link to post
Share on other sites

that's strange... the 2 should be identical. are you sure the commands you are trying to use have their corresponding programs installed?


They/Them 

Phone: Nokia 7.2 | 128GB | Android

Laptop: Apple MacBook Pro | Core i5 7360U | Iris 640 | 8GB RAM | 120GB SSD | macOS

Gaming PC: Asus Prime Z370-P | Core i3-8100 | R9 290X | 16GB RAM | 250GB SSD | Bitfenix Whisper | Windows 10

Link to post
Share on other sites
Posted · Original PosterOP
2 minutes ago, Twilight said:

that's strange... the 2 should be identical. are you sure the commands you are trying to use have their corresponding programs installed?

The script is running Basic Bash scripting

 

Here is my code https://github.com/Nolanrulesroblox/Apache2-Install-V2/blob/master/Apache2 Install and Uninstall.sh

 

Like i could do a fresh install of ubuntu (desktop) and it works fine but with the server it craps itself


PC#1 Ryzen 7 2700x GTX 1080ti 64gb GSKILL 3000mhz samsung 970 evo 1tb m.2 SSD Seagate 10tb 7200rpm HDD EVGA T2 1000W FM,80+T

PC#2 Intel i5 4200u intel HD 4400 8gb DDR3 1600 240 kingston SSD (rip laptop 2015-2018)

PC#3 Razer Blade 15 Base (i7 8750h GTX 1060 MaxQ 32gb ddr4 2400 970 evo 1tb seagate 2tb 7200 rpm HDD)

 

Servers:

Super Micro lga 775 Motherboard x5355 16gb ddr2 ECC 250gb hdd 650w psu

(MAIN server) x2 X5660 128gb DDR3 ECC, 240gb inland SSD, Samsung 850 evo 250gb, 6tb Raid 10 (SAS) x2 870W PSUs 

 

Please, take everything I say with a grain of salt. I'm not a professional, just a moderately knowledgeable nerd.

Link to post
Share on other sites
1 hour ago, Nolanrulesroblox said:

i could do a fresh install of ubuntu (desktop) and it works fine but with the server it craps itself

that is because Server is missing a bunch of stuff that Desktop comes with in order to keep it lightweight. it's possible that your script relies on some things that server doesn't come with and that need to be installed seperately. double check this. 


They/Them 

Phone: Nokia 7.2 | 128GB | Android

Laptop: Apple MacBook Pro | Core i5 7360U | Iris 640 | 8GB RAM | 120GB SSD | macOS

Gaming PC: Asus Prime Z370-P | Core i3-8100 | R9 290X | 16GB RAM | 250GB SSD | Bitfenix Whisper | Windows 10

Link to post
Share on other sites
On 2/27/2020 at 1:32 AM, Nolanrulesroblox said:

I wrote a Script to Install Apache2, PHP and a few other thins and it doesnt seem to work on the Server version of Ubuntu, but it works fine on Desktop

 

Issues:

Printf (not working)

and

Read (press enter to Continue) 

 

My Script https://github.com/Nolanrulesroblox/Apache2-Install-V2

 

 

Have this script worked on server version before?

Link to post
Share on other sites
Posted · Original PosterOP
1 hour ago, AbsoluteFool said:

Have this script worked on server version before?

The script was made on the Ubuntu Desktop but it never works on the Server version.  

for the Bash script codes

PrintF

and

Read (enter to continue) 

 

are broken, do i need to apt-get the code for bash? or?


PC#1 Ryzen 7 2700x GTX 1080ti 64gb GSKILL 3000mhz samsung 970 evo 1tb m.2 SSD Seagate 10tb 7200rpm HDD EVGA T2 1000W FM,80+T

PC#2 Intel i5 4200u intel HD 4400 8gb DDR3 1600 240 kingston SSD (rip laptop 2015-2018)

PC#3 Razer Blade 15 Base (i7 8750h GTX 1060 MaxQ 32gb ddr4 2400 970 evo 1tb seagate 2tb 7200 rpm HDD)

 

Servers:

Super Micro lga 775 Motherboard x5355 16gb ddr2 ECC 250gb hdd 650w psu

(MAIN server) x2 X5660 128gb DDR3 ECC, 240gb inland SSD, Samsung 850 evo 250gb, 6tb Raid 10 (SAS) x2 870W PSUs 

 

Please, take everything I say with a grain of salt. I'm not a professional, just a moderately knowledgeable nerd.

Link to post
Share on other sites
Posted · Original PosterOP
On 2/26/2020 at 7:03 PM, Twilight said:

that is because Server is missing a bunch of stuff that Desktop comes with in order to keep it lightweight. it's possible that your script relies on some things that server doesn't come with and that need to be installed seperately. double check this. 

Is there a way i can locate the installs for the parts of the script?

prinf and read


PC#1 Ryzen 7 2700x GTX 1080ti 64gb GSKILL 3000mhz samsung 970 evo 1tb m.2 SSD Seagate 10tb 7200rpm HDD EVGA T2 1000W FM,80+T

PC#2 Intel i5 4200u intel HD 4400 8gb DDR3 1600 240 kingston SSD (rip laptop 2015-2018)

PC#3 Razer Blade 15 Base (i7 8750h GTX 1060 MaxQ 32gb ddr4 2400 970 evo 1tb seagate 2tb 7200 rpm HDD)

 

Servers:

Super Micro lga 775 Motherboard x5355 16gb ddr2 ECC 250gb hdd 650w psu

(MAIN server) x2 X5660 128gb DDR3 ECC, 240gb inland SSD, Samsung 850 evo 250gb, 6tb Raid 10 (SAS) x2 870W PSUs 

 

Please, take everything I say with a grain of salt. I'm not a professional, just a moderately knowledgeable nerd.

Link to post
Share on other sites
43 minutes ago, Nolanrulesroblox said:

The script was made on the Ubuntu Desktop but it never works on the Server version.  

for the Bash script codes

PrintF

and

Read (enter to continue) 

 

are broken, do i need to apt-get the code for bash? or?

did you ever chmod +x the script?

Link to post
Share on other sites
Posted · Original PosterOP
5 hours ago, jdfthetech said:

have you tried to just do each command by hand on the server to figure out which thing is breaking?

The commands that are not working are printF and read


PC#1 Ryzen 7 2700x GTX 1080ti 64gb GSKILL 3000mhz samsung 970 evo 1tb m.2 SSD Seagate 10tb 7200rpm HDD EVGA T2 1000W FM,80+T

PC#2 Intel i5 4200u intel HD 4400 8gb DDR3 1600 240 kingston SSD (rip laptop 2015-2018)

PC#3 Razer Blade 15 Base (i7 8750h GTX 1060 MaxQ 32gb ddr4 2400 970 evo 1tb seagate 2tb 7200 rpm HDD)

 

Servers:

Super Micro lga 775 Motherboard x5355 16gb ddr2 ECC 250gb hdd 650w psu

(MAIN server) x2 X5660 128gb DDR3 ECC, 240gb inland SSD, Samsung 850 evo 250gb, 6tb Raid 10 (SAS) x2 870W PSUs 

 

Please, take everything I say with a grain of salt. I'm not a professional, just a moderately knowledgeable nerd.

Link to post
Share on other sites
Posted · Original PosterOP
7 hours ago, AbsoluteFool said:

did you ever chmod +x the script?

I have, the script wont run without it (Because when i put in via SFTP it shows it as a Unknown Source script)


PC#1 Ryzen 7 2700x GTX 1080ti 64gb GSKILL 3000mhz samsung 970 evo 1tb m.2 SSD Seagate 10tb 7200rpm HDD EVGA T2 1000W FM,80+T

PC#2 Intel i5 4200u intel HD 4400 8gb DDR3 1600 240 kingston SSD (rip laptop 2015-2018)

PC#3 Razer Blade 15 Base (i7 8750h GTX 1060 MaxQ 32gb ddr4 2400 970 evo 1tb seagate 2tb 7200 rpm HDD)

 

Servers:

Super Micro lga 775 Motherboard x5355 16gb ddr2 ECC 250gb hdd 650w psu

(MAIN server) x2 X5660 128gb DDR3 ECC, 240gb inland SSD, Samsung 850 evo 250gb, 6tb Raid 10 (SAS) x2 870W PSUs 

 

Please, take everything I say with a grain of salt. I'm not a professional, just a moderately knowledgeable nerd.

Link to post
Share on other sites
Posted · Best Answer
3 minutes ago, Nolanrulesroblox said:

The commands that are not working are printF and read

It's not printF, it's printf. Pay more attention to what you write. Also, printf is provided by the package coreutils, ie. apt -y install coreutils on your server. You can also add the following to your script to check for existence of printf and to install it, if it's missing:
 

which printf >/dev/null
if [ $? -eq 1 ]
then
	apt -y install coreutils
fi

 


Hand, n. A singular instrument worn at the end of the human arm and commonly thrust into somebody’s pocket.

Link to post
Share on other sites
Posted · Original PosterOP
On 2/28/2020 at 3:13 AM, WereCatf said:

It's not printF, it's printf. Pay more attention to what you write. Also, printf is provided by the package coreutils, ie. apt -y install coreutils on your server. You can also add the following to your script to check for existence of printf and to install it, if it's missing:
 


which printf >/dev/null
if [ $? -eq 1 ]
then
	apt -y install coreutils
fi

 

Sorry, in the comment i wrote F but in the script i did make it lowercase

 

Ill give it a try


PC#1 Ryzen 7 2700x GTX 1080ti 64gb GSKILL 3000mhz samsung 970 evo 1tb m.2 SSD Seagate 10tb 7200rpm HDD EVGA T2 1000W FM,80+T

PC#2 Intel i5 4200u intel HD 4400 8gb DDR3 1600 240 kingston SSD (rip laptop 2015-2018)

PC#3 Razer Blade 15 Base (i7 8750h GTX 1060 MaxQ 32gb ddr4 2400 970 evo 1tb seagate 2tb 7200 rpm HDD)

 

Servers:

Super Micro lga 775 Motherboard x5355 16gb ddr2 ECC 250gb hdd 650w psu

(MAIN server) x2 X5660 128gb DDR3 ECC, 240gb inland SSD, Samsung 850 evo 250gb, 6tb Raid 10 (SAS) x2 870W PSUs 

 

Please, take everything I say with a grain of salt. I'm not a professional, just a moderately knowledgeable nerd.

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


×