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

learn more… | top users | synonyms (2)

2
votes
2answers
27 views

Detecting in a script whether apache2 root is /var/www or /var/www/html

Apache2 recently changed the default root directory from /var/www to /var/www/html, which breaks the scripts I distribute for installing some software I wrote. Is there a reliable way of detecting ...
0
votes
0answers
9 views

How do I manage multiple application instance setup/teardown via URL?

We have a heavily developed web application, with a pretty sizable team, and a lot of things going on in many branches at the same time. For our approval process, after we've done our own continuous ...
2
votes
1answer
45 views

Bash script match grep output and send message

I am developing a script for monit status checking so I can send OK status messages to NagiOS NSCA server (passive checks). The problem I am having is that my bash script still sends messages if the ...
0
votes
0answers
14 views

Trying to create a pre-revprop-change for editing message on commit

I'm trying to add a hook to svn so that you can edit messages on commits. But whatever I do I get the same error message. Revprop change blocked by pre-revprop-change hook (exit code 255) with ...
0
votes
0answers
9 views

SQL Server Express Application Deployment Via CD

Our company has an ancient home-grown Win-32 application which uses a SQL Server Express db. We have a salesperson at a remote office who has no reliable internet and I need a way to package this app ...
0
votes
1answer
38 views

Bash — Using a character-based graphical utility to store output

I'm using bash to script a remote dialing program in an Ubuntu(14.04) server and I am having some significant trouble trying to read the output from it. I would like the program to execute as I would ...
0
votes
1answer
33 views

Finding valid email service providers in a large list of domains

I have a list of approximately 13K free email/webmail providers from circa 2000. Obviously the vast majority of these services have gone out of business, and the domains have either lapsed, or been ...
-1
votes
2answers
35 views

Server 2008 R2 - Script to kill idle sessions over [closed]

Looking for a script that can end idle session shares on a Server 2008 R2. If sessions are left open for too long there are programs that fail to update due to files/folders being open. I am looking ...
0
votes
2answers
58 views

Copy-item FileSystem provider error

Copy-item cmdlet is not working as expected, i don't understand why. This is my code : $Source = "C:\folder1" $Destination = "\\172.22.0.115\c$\folder2\" $Password = ConvertTo-SecureString ...
-1
votes
0answers
25 views

postfix wildcard to script

I run a fully functional postfix server on Mac OS X Server. A single domain, hundreds of users, mailman set and running, everything is ok. I would like to use a wildcard to process some virtual ...
0
votes
1answer
16 views

How to catch system events when a program is being updated and robotize routine steps when you update software?

I'm a support engineer for an accounting program. The program runs under Windows. I have to update many of this accounting software bases daily. I mean the software is always the same. But users may ...
0
votes
0answers
39 views

Powershell deploment script into multiple 2003 windows servers

I have created a script "test.ps1" that runs security checks on folders within machines. Now I want to deploy this script into 70 windows servers so it can run these security checks on all of them. ...
4
votes
2answers
70 views

How do I launch a command on a remote computer with an invalid domain trust? (using local creds)

I intend to use WMIC to reset the trust of a machine that is remote, and off the network. All of the following variations result in an "access denied": The following works fine: net use ...
0
votes
0answers
27 views

Howto run interactive commands, as another user [migrated]

I'm trying to write a bash script that context switches to another user (root, in this case) executes a set of commands to i. create a user (interactively prompting invoker for username) then ii. ...
0
votes
0answers
27 views

Can't figure out how to get started with powerdns-recursor lua scripting

I have a server (Ubuntu 12.04) where I run powerdns-recursor. I'm trying to add some logic to certain requests and have got my target set on lua scripting for powerdns. I don't seem to be able to ...
2
votes
3answers
202 views

Year Month day from file name in shell script

I hava file names like below adn_DF9D_20140515_0001.log adn_DF9D_20140515_0002.log adn_DF9D_20140515_0003.log adn_DF9D_20140515_0004.log adn_DF9D_20140515_0005.log adn_DF9D_20140515_0006.log ...
1
vote
1answer
58 views

Need to get a list of all users within a subnet of servers

I am looking to write a batch or vbs script to gather all users (local to the server. ie. administrators or a local account(not ad users)) on a collection of servers inside my network. I assume I ...
0
votes
1answer
28 views

virtual web folder served by PHP script

I am trying to configure my apache to be able to display (virtual) pages like: mywebpage.com/something1 mywebpage.com/something2 mywebpage.com/folder/something3 I would like these "somethingX" and ...
0
votes
1answer
41 views

Bash if statement equal output from last command

I am trying to equal something from last command with bash if statement: #!/bin/bash monit status if [ "status" != "error" ]; then echo -e "hostname\ttest\t0\t0" | /usr/sbin/send_nsca -H ...
1
vote
1answer
25 views

CGI Script not running in PHP file

I have a CGI script in the server called script.cgi and I have added the following code to the domain vhost: Action add-footer /cgi-bin/script.cgi AddHandler add-footer .htm .html I have ...
0
votes
0answers
60 views

OpenVPN - pushing script to client upon connect

Is it possible to have an OpenVPN server push scripts out to clients upon tunnel establishment? I need to set up specific iptables rules on my Linux clients and would like to be able to deploy the ...
1
vote
1answer
34 views

Using VBscript and EnumNetworkDrives, how can I instruct our login script to NOT delete a drive letter mapping and remove the rest upon each login?

I've been working on adding some new parts to an already existing login script using VBscript. I'd like to use the below code to erase all drive mappings on login. Set WshNetwork = ...
0
votes
3answers
42 views

tail -f AND allow text input

I want to create a script that allows some interactivity by tail -f logfile from myService allows text to be entered and sent to myService What I could not solve yet is this two functions working ...
2
votes
2answers
56 views

simple script to backup PostgreSQL database

Hello I write simple batch script to backup postgeSQL databases, but I find one strange problem whether the pg_dump command can specify a password? There is batch script: REM script to backup ...
0
votes
1answer
59 views

Kill child process when the parent exits

I'm preparing a script for Docker, which allows only one top-level process, which should receive the signals so we can stop it. Therefore, I'm having a script like this: one application writes to ...
1
vote
1answer
55 views

Email administrator when a duplicate IP is found on the network

It was suggested that I ask this question on serverfault. I know this is a bit of a custom requirement but I was hoping someone currently has (or can put together) a script that checks for duplicate ...
-1
votes
2answers
147 views

How to change default install path for Notepad++ in Powershell silent/unattended script

I cant figure out the parameter(s) to change the default install path C:\Program Files\ of Notepad++ to the drive I want it to install to when I run my PowerShell script. I am trying to do a silent ...
-1
votes
1answer
37 views

RSYNC only listing files when run from bash script

I am trying to copy backup files of my companies mail server to our backup server via RSYNC. I use this same script for backing up our web hosting server backup files with no issues. When I type ...
1
vote
1answer
156 views

Comparing 2 CSV files in powershell exporting difference to another file

I've write this script out, and could have swore I had it giving me a Failed early this morning but now I'm getting nothing and not sure why. Basically I need to compare $SourceAddress with ...
0
votes
1answer
44 views

Powershell pipe exporting to csv is loosing data

I'm trying to write a script that will take input from a .txt file of IP address. Do a reverse DNS lookup to get the hostname of the IP address and then export that data into .csv file. Here is what ...
3
votes
3answers
93 views

Update a network driver through GPO/AD

Our organization has just deployed new computers with Windows 8.1. Roughly 50 of them. We've run into an issue with the driver on the new computers which is flooding the network with ipv6/multicast ...
1
vote
0answers
59 views

Linux Script to login to Raspberry pi and run some scripts inside raspberry pi [closed]

This is my scenario, We have some sensors on different sites, these sensors are connected with some equipment having SIM cards in it to allow the internet connection. On the other hand, we have a ...
5
votes
5answers
390 views

Bash: mv directory one at a time

I am trying to move all subdirectories of a folder to another share on the same server. If I do a mv *, I will run out of space since the folders are not removed until all folders get transferred. ...
1
vote
2answers
30 views

Debugging powershell init

My problem is that I just reinstalled my system and have installed heaps of packages via Chocolatey. However now when I launch powershell, something changes the fonst type and size inside the console ...
-1
votes
1answer
40 views

how to set linux hostname based on flashdisk volume label [closed]

i'am running live linux, which run from FAT32 flashdisk since i run a lot of pc using this flashdisk, its difficult to identify which IP for its hostname, since its ip need to be dynamically ...
2
votes
2answers
46 views

Get hostname from url using Trafficscript

I'm looking to get the hostname from a URL as it comes through Zeus and I've looked through the documentation on Trafficscript and it seems like the only option is regex. Doe Trafficscript have a ...
1
vote
0answers
38 views

Openvpn-server: Execute a script when on a failed connection?

Good morning, I was wondering if It was possible to setup something to execute a script when someone tried to connect but the TLS check failed (When someone who is not supposed to connected try to° ...
1
vote
1answer
38 views

Updating usernames and passwords for 450 WordPress databases - 450 ftp Accounts and 450 MySQL user

How would you update these in a consistent, reliable manner? I'm new enough to system administration, self taught and still learning but - I have this problem to solve in no specific time and under my ...
0
votes
0answers
35 views

Solaris /etc/xdg/autostart root script pam_authenticate conversion failure

Im running SOL11.1 and have setup a desktop file to run in /etc/xdg/autostart this calls a main script which calls other scripts. The regular commands work. But the sudo commands doesn't seem to ...
1
vote
0answers
35 views

Using Windows as middle for migrating between two Linux machines

We're developing a tool that will do a migration between some platforms. Both source and/or destination servers can be Windows or Linux. The tool is currently built in .NET and we'd like to keep it ...
0
votes
0answers
23 views

Script to apply Simple Finder restrictions to Mac OS X user?

Is it possible to script (e.g. with AppleScript or bash shell script) applying the Simple Finder and an associated application whitelist to a local user account on Mac OS X? We are using Mac OS X ...
0
votes
1answer
91 views

Create a trigger when a mobile connects at network [closed]

I'm a complete dummie on Network subjects. I'm trying to create a log, when a specific iPhone/Cellphone connects into a wireless network. The main goal is pull a trigger (create a log file, send a ...
0
votes
1answer
43 views

Curl pressing enter or ctr+c in order to have the right response [closed]

This is a script that checks my current ip on this site: http://myip.dnsdynamic.org/ and pick the response and calls an API in order to update my dynamic ip. Here the script: curl --user ...
0
votes
3answers
105 views

Exclude with the find command [duplicate]

I need some help getting the find command to work right in a script working on. I need to be able to exclude some directories. Below I have what I'm doing as a work around. sudo find / ( -name ...
0
votes
1answer
368 views

GPO: User logon script not running

I have a GPO that is linked to an OU containing computers. Loopback processing is activated an set to merge. Within the user part of the GPO i have a powershell script defined that basically checks if ...
-1
votes
1answer
47 views

Make a copy of email using pipe in postfix alongside 1 content_filter

I am using postfix and already usHi. I am using postfix and already using a script as a content_filter which re-injects back to smtpd to all users, but before this happens, I would like to make a copy ...
2
votes
2answers
1k views

Powershell: Single Script to “clean” multiple folders of files older than

I would like to create a maintenance script that would run on each of our servers to clean out common drop/archive directories. Preferably the script would use a reference file for the folder path ...
1
vote
1answer
23 views

How to get a debug output from the find command?

I have the following find command: find /home/ -type d -name "something" what I want to achieve is to know which directory/file is checked by the find command no matter the fact that it does or ...
4
votes
2answers
88 views

OK to modify HKLM\Software\Policies and HKCU\SOFTWARE\Policies on a domain?

Background: I have a domain (2003 Functional Level) with a mix of Windows XP and Windows 7 clients. We have been using Group Policy to manage our workstations. Now, I am in a situation I need to ...
10
votes
3answers
454 views

Deploying Printers via GPO/GPP - is there a programmatic option?

For reasons beyond my control, I've been tasked with setting up GPO/GPPs to deploy our 100+ printers to our 1000+ clients. The good news is that we have over a dozen sites, and for the most part, I'm ...