0
votes
0answers
9 views

Create startup script for openproject [duplicate]

I consider myself a linux noob, but I was able to install openproject on a Ubuntu 12.04 server in VirtualBox. Currently I have to manually start the web-server every time I power-up the virtual ...
0
votes
4answers
33 views

SSH remote command execute stays without disconnect when finished execute?

I am trying to build a script/command that will restart our Asterisk/Elastix service on our PBX. The script is basically using simple command with auto log-in public key that run from Ubuntu ...
-1
votes
1answer
50 views

Why can't I update my system via shell script?

I have a very simple script, let's call it update.sh: #!/bin/bash echo "Updating system..." sudo apt-get udpate sudo apt-get udgrade Running this script, throws the following error: me@host $ ...
1
vote
2answers
37 views

Running shellscript with cronjob is making problems, executing manually not. Ideas?

I made a shell script called /home/root/cron_grads.sh (chmodded 755) on my server. In this directory are more grads-scripts like 500hPa_p0.gs (644). My main script creates a temporary file ...
1
vote
1answer
62 views

Copy a file from ubuntu server to a nas drive

I would like to use a script to copy a sql file to a nas drive location. for example it would copy backup.sql to //10.1.1.124/backup/Backups.
0
votes
0answers
70 views

Run multiple scripts using one script on boot?

I need help. I've tried several methods to get this to work. Basically, I home host a server on my PC, the problem is, I want it to be online when logged in as every user on the computer. It uses ...
-1
votes
1answer
37 views

Rename default “Ubuntu one” folder on 12.04 server possible? [duplicate]

I'm running Ubuntu 12.04 server from home and using Ubuntu One as backup site. I'm not great at scripts (beginner) so when writing bash scripts that I later crontab for backups, having to use "Ubuntu\ ...
1
vote
1answer
54 views

Live CD: Script doens't work correctly after login

I have a PXE/NFS Server (192.168.1.10), a client PC and a diskless PC. I installed base ubuntu to client PC. I wrote this script (update.sh) to work after login to client PC. SERVER=192.168.1.10 echo ...
1
vote
2answers
659 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 ...
5
votes
1answer
166 views

How to set my Bluetooth python script on higher priority than Ubuntu's request?

I have got a Bluetooth Python Server Script on Ubuntu to connect with an incoming request from a Smartphone device. However Ubuntu's Bluetooth is getting the request before my script can react on it. ...
0
votes
2answers
2k views

Run scripts automatically in server after ssh connection

how to run a script automatically in server soon after client system establish ssh connection with the server for ex: suppose a user will logon to my computer from another system(connected via lan) ...
5
votes
3answers
768 views

Script that delete files after 5 days

Is it possible to make a script that will delete files in a specific folder, after five days without deleting the folder(s). I am using Ubuntu server 12 without gui interface.
0
votes
1answer
608 views

SSH - How to force execution of a script ( /etc/sshrc , ForceCommand, .. ? ) on login but still allow execution of the client's ~/.ssh/rc?

As far as i know upon SSH login the following files are executed [SERVER] /etc/environment [Client] ~/.ssh/environment -> can be locally overriden by "SSH_ENV" environment variable -> will ...
0
votes
1answer
1k views

Ubuntu FTP script to take backup and upload in my FTP server

Hie all I am trying to backup of my application directory, database backup and then sending it to my ftp server at hetzner by using the following script and i get few errors my server details: ...
2
votes
2answers
103 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 ...
0
votes
1answer
29 views

A bit of help with cron script please

I would like to set a cron on an ubuntu server to download a file to a specific location. How would I go about this? For example once a day I would like my ubuntu server to look for a file on a ...
0
votes
0answers
88 views

Command to map network share folder

I have a Ubuntu server as my file server. I then have other pc's and laptops on the same network. My server has ssh but default ssh port was changed to (2345) My question is what is the command that ...
1
vote
1answer
300 views

Post-login scripting for Dovecot not working [closed]

I have Dovecot 1.2.12 running on Ubuntu Server 10.10 and I'm trying to get a post-login script to log the date and time that the users access their IMAP mailbox. I've read the Dovecot wiki and added ...
0
votes
2answers
3k views

Why can't I write to a file even after 777 permission?

On my ubuntu server I have Apache and PHP and all that nessory stuffs.. but when I run a php file <?php ...
1
vote
2answers
404 views

Cron job isn't working

I have an sh file called m.sh with the contents: echo "Cleaning memory" sync; echo 3 > /proc/sys/vm/drop_caches echo "" free -m echo "" ps cax | grep java > /dev/null if [ $? -eq 0 ]; then ...
3
votes
1answer
8k views

Run script at boot/startup in Ubuntu 12.04 x64 Server

I am trying to start the RoR application named fedena. What I generally do is SSH login as rootand hit these commands root@cloud:~# cd fedena root@cloud:~/fedena# script/server => Booting WEBrick ...
11
votes
3answers
11k views

Why is the command in /etc/rc.local not executed during startup?

I have a single command in my /etc/rc.local script that is supposed to start the update daemon for Tiny Tiny RSS during startup, but the script is not executed during startup. Why? The entire ...
1
vote
2answers
386 views

Start or Stop a server with a single script launcher

I made 2 .sh scripts to start and stop Xampp server. I'd like to merge them in a single launcher to obtain something like a ON/OFF button, so that if Xampp has already been started it would stop, but ...
2
votes
1answer
545 views

Script to change permission on content, and move files to other folder

I have a program that downloads some files. I want those files to automatically change permissions to 755, and get moved to another folder on my system. I want this to autorun every hour. Is this ...
2
votes
2answers
1k views

Script/tool to clone a ubuntu server

I have installed and configured a ubuntu server (installing additional packages and making modifications to some configuration files). Now I would like to install an almost identical system, which ...
0
votes
1answer
179 views

On Ubuntu Server 12.04, how do I make a shell script that replaces underscores with spaces recursively?

So far I have: for file in *\_* do file_clean="${file//_/ }" mv --verbose "$file" "$file_clean" done However, it only renames files in the root directory of the folder. How do I make it rename the ...
1
vote
1answer
36 views

A script to call /opt/myfolder/myscript

I am try to have it when I log into the server that all I have to do is type start myscript from the location of /opt/myfolderofscripts/myscripts and also have it say starting script. I don't want ...
1
vote
2answers
2k views

Auto shutdown server if there was no activity

My server should shutdown after 01:00 am, if there was no activity in the past hour. Lets say there was the last connection at 00:43 then it should check again at 01:43. How to write such a ...
5
votes
2answers
684 views

Enabling unattended-upgrades from a shell script

I have a shell script to automatically configure new Ubuntu virtual machines for my purposes. I would like this script to install and enable unattended-upgrades, but I cannot figure out how to do so ...
3
votes
3answers
537 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 ...
1
vote
1answer
122 views

Multiple Users Sending Input To The Same Server Running On My Ubuntu Server

I've just recently started hosting a Java based server on my Ubuntu Server. I've been learning how to setup everything and I've been feeling pretty good about it's setup. I currently start the ...
6
votes
2answers
15k views

.sh script won't run [duplicate]

Possible Duplicate: How do I run .sh files in Terminal? I'm trying to install Craftbukkit on my Ubuntu 12.04 server. However, I'm having issues with step seven, which instructs me to run ...
5
votes
1answer
2k views

blackhole exploit kit - Linux Server Script

It has come to our attention when scanning some of our hosted server websites that they have been infected with Blackhole Exploit Kit (top dollar hacking program - ...
7
votes
3answers
25k views

How can I tell if my hourly cron job has run?

I have created a file called ntpdate in /etc/cron.hourly #!/bin/sh /usr/sbin/ntpdate-debian date > /tmp/william_tmp date > /william_tmp date > ~/william_tmp echo test I also did Chmod 755 ...
0
votes
2answers
443 views

How do I decrease the timeout on ifup?

I'm writing a shell script that brings up an Ethernet interface (configured for DHCP) to determine whether it's connected to a network. If it isn't, I'd like to be able to report in a timely manner ...
2
votes
1answer
4k views

Startup script for a specific user on Ubuntu Server

Here is the command I want to be run at startup: VBoxHeadless -s "pfsense" as user "enedene". Could someone give me step by step instructions?
3
votes
2answers
2k views

How to create a s3ql file system and mount it automatically on boot?

I've been experimenting with s3ql on Ubuntu 10.04, using it to mount Amazon S3 buckets. However, I'd really like it to mount them automatically. Does anyone know how to do that? Solution: Thanks ...
3
votes
2answers
7k views

Remotely run a command on a ssh-server with a script

I want to run a command on a ssh-server, but this command is determined by a script on my local machine. How do I do that? An example for clarity: I want to write a script here (foo.sh) that takes an ...
6
votes
3answers
7k views

Run (system) script on SSH login and/or logout

I'd like my OpenSSH server to start a script whenever a user logs in using SSH, ideally passing the host name or IP, as well as the user name. Additionally I'd like it to run a script, whenever a ...