1,891 Topics
| |
Can anyone give me an example of a DOS BAT file (script) that could FTP a file (variable)? I've got the Linux problem solved, but I need to do it in a DOS environment. Thanks, John | |
hello everybody. i am attempting to use a script which returns the error: bash: ./script.sh: /bin/bsh^M: bad interpreter: No such file or directory upon "chmod"ing and executing. the code is: [CODE]#!/bin/bsh grep 'Time : ' rob_onholiday298.gout | awk '{print $4}' > temp1 grep 'Total energy ' rob_onholiday298.gout | awk '{print … | |
Hi every one, I am currently working on a server program which executes a series of system commands on receiving a messgae from the client(in C). what the server essentially does is he cd's into a particular directory and executes a shell script that calls make utility and does some … | |
Hi Friends I have two server 1. server 1 2. server 2 I want to execute a shell script in server 2 from server 1. shell script will returns few data i need to check in server 1 Please help me in this | |
Hello Guys, I am new to Shell Scrpting but I am learning quickly. My script looks as follows: #!/bin/sh su - postgres echo "Please enter the password for a2billing user and confirm it: " createuser -W -S -d -r -e a2billinguser createdb -e -O a2billinguser a2billing exit 0 With above, … | |
I'm running on a Linux machine and can't get FTP uploads working. Here's my script: HOST='ftp.name.com' USER='username' PASSWD='mypwd' FILE='f1020811' DIR='/data_dir/send' echo ************************************************************** echo * Attempting FTP * echo ************************************************************** ftp -n -u -d ftp.name.com <<END_SCRIPT quote USER $USER quote PASS $PASSWD put f1020811 END_SCRIPT I noticed using $HOST was rejected. … | |
Hi all Please help me in this problem: Suppose i have hundreds of files in one directory with different extenshions, I want to rename all filenames. [COLOR="Green"]filename[/COLOR] required filename [COLOR="Green"]XYZ[/COLOR]bla.java with [COLOR="Red"]ABC[/COLOR]bla.java [COLOR="Green"]Xyz[/COLOR]bla.java with [COLOR="Red"]Abc[/COLOR]bla.java [COLOR="Green"]xyz[/COLOR]bla.htm with [COLOR="Red"]abc[/COLOR]bla.htm please tell me about shell script for this. regards Abid | |
I am using ext4 filesytem on fedora 13 and also Windows 7. Tried linux internal reader, ext2fsd and many more to fetch data from ext4 partition but unable to do so. Can any one help to access data in Linux partition from Windows 7. Thank You | |
Hi there, I have a script in my intranet to which I have 100% rights to run through browser using exec(); passthru(); system(); etc with php. Now we use this to make automated backups per user database of certain systems connected. Very simple for the end-user after done working and … | |
Please let em know if this is valid....... I am trying to run mysql from my shell script by passign a parameter.the sql(script.sql) is in directory $mydir and the parameter is $date and trying to run it this way: un="username" pd="PASSWORD " dbname="dbname" result = `mysql($un,$pd,$dbname,$mydir,"script.sql",$date)` I am trying to … | |
Hi, I want to create a program that will synchronise a folder on my laptop(running OS X) and a folder on a remote server(running Linux). For example, the program is contained in a subfolder on my laptop, when I run it, it ssh's to the remote folder and loops through … | |
Need help with following date conversion: I have my dates as 08/02/2010 and I want to convert into 8/2/2010, incase date is 18/12/2010 I want to be same way. Please guide me. | |
Dear all I would like to read the input from user #!/bin/csh echo "Please enter a number:" set cutoff = $< # C shell input from stdin cluster_struc validate_rmsd.disp $cutoff 4 | cat > file1.out cluster_struc validate_rmsd.disp $cutoff 4 | wc > file2.out then read the number of line of … | |
Hi, I have written a script that sends daily emails. I want a certain part of the mail text to be in bold. Please advice me on how to achieve this? Thanks. | |
Hi all, I literally only started looking at shell a couple of hours ago. I am looking to do just one task, which I think should be quite straight forward. I will try explain it as best I can......... Basically I am trying to automate the grep command from ubuntu … | |
Hi, I was recently asked in an interview the number of processes that are created when I enter in a command that contains a pipe. For eg. If I enter the command: $who | tee /dev/tty | wc -l Could anyone tell me how many(which) processes are created and in … | |
Hi there, I'm making a simple shell program in [B]pico using Unix[/B]. I was given most the code from a tutor and added bits to it, it's supposed to go to a prompt allowing user to type but instead it does nothing. [B]No errors are shown.[/B] Btw: i use [B]gcc … | |
Hello there - I have three directories. I would like to compare directory1 with directory2, then take those changes/new files and copy them over to directory3. I was given the following code: [code] #!/bin/bash dir2="d1" dir1="d2" dir3="d3" for file in dir2/*; do file_in_dir1=dir1/$(basename ${file}) if [ ! -e ${file_in_dir1} ]; … | |
Hi Experts, I'm newbie in Shell Srcipt Programming. I want to copy some binary files to remote server through ftp script. I got a script which is working fine like coping files to remote server. But I want to put some conditions in script like if the file already exists … | |
If I have the following line in a bash script, it works fine: [CODE]CoDescDate=$(awk -F"\t" '{print $22}' $1)[/CODE] If I embed the above line in a function that is within the same bash script, the script seems to hang at the point of invoking the function. [CODE]pay_ending_date () { CoDescDate=$(awk … | |
Can someone tell me how to print a dollar amount (i.e. 1140.95) as 114095? | |
Hello friends, I have text file which contains more than million phone numbers. Here is the example. I want to extract all numbers and put it in a excel single row file. [QUOTE]07748362656 07532517142 07946132831 07532135934 07880531707 07816820456 07879181057 07928483273 07735721101 07668889152 07925787076 07041438421 07524774407 07948383594 07927231600 07796044906 01679953124 01615331860 … | |
We try to search and remove duplicate files and need the best program for this purpose. | |
Hi, What is a log file?What is its purpose?How do I open, read and write to log files? Thanks, Toms | |
I am using Ubuntu-gcc and have a large C code which uses routines from numerical recipes and GNU scientific library. It needs a compilation compilation because each library, i.e. nr and GNUsl, needs its own flags for gcc. Therefore I use a makefile. It works well when the code is … | |
Hey Everyone, Shell programming is something I haven't learnt or tried before.. but I kind of need it to automate backing up my website. At the moment, I have: [CODE]#/bin/bash /bin/tar czPf /home/cpanelusername/etc/files/wp-content-weekly.tar.gz /home/cpanelusername/public_html/wp-content/[/CODE] but how do I get it to email me the file wp-content-weekly.tar.gz and then delete it? … | |
hi, Im just a novice in shell scripting,can you help me out; all inbound files will now have timestamp. the timestamp will be get from a server,specifically on a Moveit server. any help will do.. thanks. | |
HELP ME, I accidently ended explorer.exe (my shell) in Task Manager. I went to New Task>explorer.exe>run and it only opened windows explorer but did not open my shell. | |
I am trying to write a script that can accept multiple options. The issue that I'm having is some of the potential input will be search criteria. The syntax would be: script [list of patterns] [-t seconds] [-n count] All of the arguments are optional. So far, my thoughts were … | |
Hi I am tryibg to check for presance of a string in a big string. I tried as follows: [CODE]IS_VECTOR_TEST_CASE=`grep AIV "$PWD"` if [ "$IS_VECTOR_TEST_CASES" = "" ] then #do something else #do something fi[/CODE] This always giving me as if [ "$IS_VECTOR_TEST_CASES" = "" ] is true with following … |
The End.