1
vote
1answer
102 views

execute local bash script in remote machine using expect

I have local shell script. Now, I want to run this local script in remote machine. Of course I can use ssh, but as it(the local shell script) should be like an automated one, it shouldn't ask for ...
1
vote
2answers
99 views

Create a Screen session with a bash script using contab

I want a .jar file to run every time the server boots up (we're using a VPS), and so I've edited crontab using crontab -e and then adding @reboot bash /home/bash/startserver.sh. But I haven't even ...
2
votes
1answer
57 views

Is there a way to access a live command shell for Ubuntu server online?

I have setup a LAMP server with ubuntu server that I plan to do some game hosting with. Right now I am using Webmin for remoting in to my server. One major problem with webmin however, is that you can ...
2
votes
2answers
92 views

How to create scripts that create another scripts

I am writing an script that needs to generate another script that will be used to shutdown an appserver... This is how my code looks like: echo "STEP 8: CREATE STOP SCRIPT" stopScriptContent="echo ...
2
votes
1answer
2k views

Configure / Add a FQDN to /etc/hosts?

I'm trying to set up iRedmail 0.8.5 and I keep getting this error. root@danielbts11:~# cd /home/iRedMail-0.8.5 root@danielbts11:/home/iRedMail-0.8.5# bash iRedMail.sh hostname: Name or service not ...
0
votes
1answer
340 views

problem with PATH when using $su

OK, I'm having a bit of an issue with PATH and running a process as another user under Ubuntu. First, we check where the bin is: root@host:~# whereis start-stop-daemon start-stop-daemon: ...
1
vote
2answers
217 views

constantly check if the virtualbox is started or still booting up from a script

I am writing a shell script to start a virtualbox (ubuntu). After the command I want to put a for loop to keep checking the status of virtualbox and the script comes out of the loop only after the ...
4
votes
2answers
3k views

xclip on headless server

I've been using xclip to copy the output of bash commands like so: pwd | tr -d "\n" | xclip -selection c So that I can then paste the output into another terminal session. I was trying to use it ...
1
vote
2answers
369 views

Activate dash after minimal GUI installation on Ubuntu Server

I installed the ubuntu desktop package without recommends on Ubuntu server 12.04 and noticed that dash does not work - it just won't find any applications (screenshot). How can I activate it? I assume ...
0
votes
1answer
72 views

bash permissions

My friend was trying to tighten up security on his ubuntu server and changed the permissions on bash. He logged out, and now the computer won't let him log back in. The server is an off-site server ...
11
votes
1answer
541 views

How can I programmatically determine if a system is a desktop or a server?

Is there any way to distinguish between Ubuntu Server and Ubuntu Desktop? I have a Bash script (shameless plug) that I use to set up lightweight web servers, and I've noticed that when I run this ...
5
votes
1answer
133 views

I Recently Installed Ubuntu Desktop GUI Over My Ubuntu Server Install and I Broke Some Bash Commands

I have been running a virtualbox of Ubuntu Server for web development and have been getting along quite nicely. I decided to install Ubuntu Desktop via "sudo apt-get install ubuntu-desktop" so I can ...
3
votes
1answer
441 views

Locale warning while executing adduser

I just tried to add an user to a group $ adduser someuser sudo perl: warning: Setting locale failed. perl: warning: Please check that your locale settings: LANGUAGE = "en_US:en", LC_ALL = ...
3
votes
1answer
68 views

no features in bash in new vps?

I have 12.04 server minimal running on my VPS. When I ssh into the server, only $ is showing at the prompt for each prompt. There's no typical <directory> <username>$, no autocompletion ...
3
votes
3answers
501 views

need a different backup solution

I just built a new media/backup server using Ubuntu 12.04 64bit. I installed a hard drive to be used only for music, pictures, and videos and formatted it fat32 so my 1 and only Windows PC could map ...
4
votes
1answer
210 views

Why Byobu custom status notification code fail to show in color?

The code below runs well in Bash and shows text with proper green background color but when I add it to the ~/.byobu/bin/ folder it shows the escape characters instead. Something like ...
3
votes
2answers
3k views

How to replace/fix a messed up /bin/sh and /bin/dash

I have corrupted my /bin/sh and have no idea how to replace it. I accidentally copied over it. How can I fix this? I am running Ubuntu Server 11.10, no X. update: I have tried the fix that was ...
4
votes
1answer
849 views

Cancel Process with Ctrl + C will not work in Terminal

I have just got myself a Ubuntu server and for some reason the Ctrl + C will not kill the process I am running. I have run this command on two terminals Cygwin and putty and logged in using ssh. I ...
3
votes
2answers
147 views

Batch Starting Servers

How I can create a batch alias for bash? I need to do this: cd /somefolder bundle exec unicorn -p 3000 rackup faye.ru -s thin -E production bundle and rackup - this is 2 servers for example I ...
2
votes
1answer
1k views

Typing commands into a terminal always returns “-bash: /usr/bin/python: is a directory”

I think I messed something up on my Ubuntu server while trying to upgrade to Python 2.7.2. Every time I type in a command that doesn't have a response, the default from bash is this: -bash: ...
2
votes
1answer
727 views

Upstart scripting: Start service and immediately run another command

Here is my current Upstart script I've placed at /etc/init/redis.conf: description "redis server" start on runlevel [2345] stop on shutdown exec sudo /opt/redis/redis-server /opt/redis/redis.conf ...
0
votes
1answer
157 views

What command runs when I SSH into a server?

When I SSH into a server, I see the MOTD then I am in BASH. What command is running that takes care of displaying the MOTD and then starts the shell?