I am having trouble running a .sh file. The code 'x=${file_name:0:$z-11}' is giving me a bad substitution error. However when I run in BASH it works. Thing is when this goes to production the .sh will not be running in BASH. Is there a way to substring a string not in BASH or a way to invoke... (2 Replies)
Hi
I get the following error while executing the shell script. I did not get an error when I ran the script in a different environment (unix server).
str-token.ksh: 0403-057 Syntax error at line 20 : `(' is not expected.
This is the line which gives error
string=(${pos_array})
Please find... (3 Replies)
ok i have a very simple UNIX script
#!/bin/bash
TERM=ansi;export TERM
PFCMARK=25;export PFCMARK
umask 0000
PFUMASK=000;export PFUMASK
#run for filepro menus and exectuables
echo "###########File Modification Log.############\r" > "/public/appl-fp$(date +%m-%d-%Y).txt"
find /appl/fp/... (10 Replies)
So I have this rsync script I wrote to grab some sql files and import them to a database. I left in the mysql stuff just give context to the situation. The real problem is with my rsync code.
script.sh (chmod 744)
#!/bin/sh
rsync -av --rsh="sshpass -p'PASSWORD' ssh -l'USERNAME'"... (3 Replies)
Hi,
The following assigment is not working within shell script but is working from command line. Could anybody advise why? OS - solaris 8
APPL=`grep "$Application" ldapapps |awk '{print $1}'`
echo $APPL (5 Replies)
Please help me understand how sort -k3,3 -k 4,4 short* works , is it sorting 3 and 4 th field ? what is the use of specifying 3,3 and 4,4 in sort and what is actually does and i see sort -k3 short* and sort -k3,3 -k 4,4 short* giving the same output.
Sort output attached
Please help (2 Replies)
SUID works for shell scripts (bash)??
I'm user user1 need to execute a shell script (script.sh) which is owned by user2.-rwsrwxrwx 1 user2 aduser 3518 Aug 21 05:33 script.shOnly user2 has write privileges to write/copy a file in directory /dir1/subdir. Hence SUID bit permissions are set to... (8 Replies)
I have a file with two line, one is header, the other actual value:
TYPCD|ETID2|ETID|LEG ID|PTYP|PTYP SUB|TRD STATUS|CXL REASON|CACT|CACTNM|ENCD|ENC
D NM|TRDR|ASDT|TRDT|MTDT|STDT|LS|SECID|SECID TYP|SECNM|PAR|STCC|MARKET PRICE|DIS
MARKET PRICE|MARKET PRICE CURRENCY|SRC OF SETTLEMENT... (2 Replies)
Discussion started by: digioleg54
2 Replies
LEARN ABOUT SUSE
plmpower
plmpower(8) powerman plmpower(8)NAME
plmpower - control Insteon/X10 devices via SmartLabs PLM 2412S
SYNOPSIS
plmpower --device serial-port
DESCRIPTION
plmpower is a helper program for powerman which enables communication with Insteon/X10 devices via SmartLabs Power Line Modem, model 2412S.
It is run interactively by the powerman daemon. It can also be useful as a standalone tool for debugging X10/Insteon networks based on the
above device.
NETWORK SETUP
Note the addresses of your Insteon/X10 devices. Plug the PLM into an AC outlet, preferably on the same electrical phase as the devices
under control. Devices are available to bridge phases if this is not possible.
Attach the PLM's serial port to your computer, and ensure that nothing else is using the serial port such as the system console or
getty(8). Run plmpower and try the interactive commands below to see if the devices respond reliably.
Once everything is working, configure powermand to run plmpower as a coprocess as described in powerman.conf(5).
OPTIONS -d, --device serial-port
Specify the path to the special file connected to the PLM's serial port.
-t, --timeout msec
Set the Insteon timeout to the specified number of milliseconds (default 1000).
-x, --x10-attempts number
Set the number of times to run every X10 command (default 3). X10 does not provide an ACK/NAK mechanism like Insteon so we cannot
be certain that any particular X10 command completed, therefore X10 commands are issued multiple times to increase confidence.
INTERACTIVE COMMANDS
The following commands are accepted at the plmpower> prompt. Address arguments may be Insteon (e.g. 1A.2B.3C) or X10 (e.g. G12).
help Display help on the available commands.
info Get info about the PLM.
reset Reset the PLM (clears the all-link db).
on addr
Turn on device.
off addr
Turn off device.
status addr
Query status of device (Insteon only).
ping addr
Time round trip request/response to device (Insteon only).
FILES
/usr/sbin/plmpower
/etc/powerman/powerman.conf
ORIGIN
PowerMan was originally developed by Andrew Uselton on LLNL's Linux clusters. This software is open source and distributed under the terms
of the GNU GPL.
SEE ALSO powerman(1), powermand(8), httppower(8), plmpower(8), vpcd(8), powerman.conf(5), powerman.dev(5), powerman-devices(7).
http://sourceforge.net/projects/powerman
powerman-2.3.5 2009-02-09 plmpower(8)