Jump to content

Issue with Ubuntu 19.10 Server

Go to solution Solved by WereCatf,
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

 

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

 

 

Link to comment
https://linustechtips.com/topic/1159581-issue-with-ubuntu-1910-server/
Share on other sites

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?

She/Her

Phone: OnePlus Nord CE 5G | 128GB | 8GB Ram

Main Desktop: Ryzen 5 3600 | GTX 1060 6GB | 32GB Ram
Main Laptop: Acer Aspire V3-771G | Core i7 3612QM | 16GB

Link to post
Share on other sites

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

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. 

She/Her

Phone: OnePlus Nord CE 5G | 128GB | 8GB Ram

Main Desktop: Ryzen 5 3600 | GTX 1060 6GB | 32GB Ram
Main Laptop: Acer Aspire V3-771G | Core i7 3612QM | 16GB

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

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?

Link to post
Share on other sites

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

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

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

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

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

×