Questions tagged [scripting]

A form of computer programming that — in the context of system administration — lends it self well to automating tasks.

A form of computer programming that — in the context of system administration — lends it self well to automating tasks.

Scripting is usually done in a scripting language. Such scripting languages are often dynamically typed and interpreted, as opposed to compiled languages. Examples of such languages include PowerShell, Perl and Bash.

1826 questions
0
votes
1 answer

Have a script which adds Security on share to "Everyone"

[Old post] I have a shared folder on the network which is shared with "Everyone" 'Read' & 'Read & Execute' privileges. A few people have 'Write' access and sometimes somehow when they either copy, move or save a document inside that folder the…
0
votes
2 answers

Problem with loading .sh files call out by /usr/bin/php

When my web site is calling out a bash script with /usr/bin/php i'm geting this error Failed loading /projects/common/zend/lib/ZendOptimizer.so: /projects/common/zend/lib/ZendOptimizer.so: cannot open shared object file: No such file or…
B14D3
  • 5,188
  • 15
  • 64
  • 83
0
votes
2 answers

Robocopy website deployment script log file name truncated in AM

This is an IIS website deployment script I started to write. It moves files from directory A to directory B and creates a log file with the date/time as the file name. When it's run in the AM hours, the time part of the log file name gets…
JustBeingHelpful
  • 1,964
  • 7
  • 37
  • 53
0
votes
3 answers

Deleting the oldest file in a folder with batch scripting

I have to write a batch file to delete the oldest file in a folder, but i don't know how to get the name of the oldest file. I can sort files with DIR, DIR /B /O:D /T:C but this is a list and i need the first file (since it sorts the oldest first)…
Hayri Uğur Koltuk
  • 103
  • 1
  • 1
  • 4
0
votes
1 answer

How to identify device and its IP on network by MAC on Ubuntu 10.04+?

I have a NAS (LinkStation Mini). Its windows software identifies it correctly. I want to identify device and its IP and mount the same.
Jigar Shah
  • 159
  • 1
  • 5
0
votes
3 answers

Shell script does not work with cron

I have this shell script at /usr/local/1.sh: #!/bin/sh wget -r -np --user=peter --password='123' ftp://67.225.87.95/ -p /test/ If I run it using # sh 1.sh the script executes ok and does what its supposed to do. But if I create a cron job to…
user86187
  • 33
  • 1
  • 5
0
votes
1 answer

Remotely reinstall dbus and libdbus

OS: Ubuntu 11.04 amd64 After several updates, dbus didn't get to install correctly (carelessly used &&; long night), which I found out after server restart – no network services are accessible. Only way that I can connect is to request recovery…
0
votes
1 answer

Network drive: move generates an error

I'm trying to create a script in an application. The application should call cmd.exe and cmd.exe should run a statement pushd \\file\share && move filename.txt \\file\share\newfilename.txt && popd But this generates an error in an…
jrara
  • 209
  • 2
  • 6
  • 14
0
votes
2 answers

Add Group Policy by Script

I'm trying to make it easy to add a LogOff script to Group Policy and am having difficulty finding any information on adding Group Policy via script. I already have the script I want to run at Logoff, I know how to run scripts via Group Policy. I…
music2myear
  • 1,905
  • 3
  • 27
  • 51
0
votes
1 answer

How to write a shell script for OS X to log in to a remote server via SSH and execute commands

This seems simple enough... I'm trying to write a script that I can just double click on in OS X. The script is to login via SSH to a remote server, run a git commit and exit. When I copy/paste my commands into terminal they work but when I save…
jb510
  • 212
  • 1
  • 4
  • 9
0
votes
1 answer

sync a file over 2 servers and switch between what server is being connected to

I do not know for sure if this is the correct location to post this, but I am looking for software or a script to be able to do what I am wanting... or if anyone has anything better. In short, there is a file that gets updated on a server. I need…
Patrick
  • 401
  • 3
  • 5
  • 15
0
votes
3 answers

Redhat Shell Script If Statement fails with odd syntax error

Redhat 5.3 Enterprise The following Shell script is used to check and see if a backup directry is named "ll_backup", then changes it to equal the content of a file RESULT.VAR. The result.var file is copied for log purposes to another directory. I…
TrevJen
  • 264
  • 1
  • 7
  • 23
0
votes
1 answer

Find zero byte files

I'm looking for a modern (though not PowerShell) script to help me find zero byte files newer than say, 12 hours. The BAT scripts I'm finding on the web aren't working well. Server is Windows 2003 and I have tens of millions of directories to…
Dave P
  • 396
  • 1
  • 4
0
votes
2 answers

Script to run vpnc, and enter password

My vpnc connection is breaking quite often, and my friend created a script, which runs vpnc, and runs another "guard" script, which in turn checks every minute if vpnc is still connected, and connects it if it is not. The difference between me and…
amorfis
  • 737
  • 2
  • 14
  • 31
0
votes
1 answer

Setting metrics in ubuntu for eth0 and wlan2

I have two scripts, one copying files from machines on closed network (no internet) to the hard drive of the laptop and the other script trying send these files to over the internet using the wlan. eth0 fixed IP address wlan2 dhcp address I…
Grimlockz
  • 325
  • 1
  • 2
  • 11
1 2 3
99
100