Ubuntu :: Save The Output In A File (or Log) To Check If Error?

Mar 10, 2011

I have a bash script that i created for a colleague to configure the servers he installs. It does package installations, modifies some config files, creates directories.

The problem is sometimes he says that the script skips some steps. There are some steps that require user input and i think he chooses wrong option. (i have tested the script and it works fine).

My question is how can i save the output in a file (or log) so i can check if there are error? I know about the ">>" operators but will this "script.sh >> output.txt" still bring the dialogs for user input (like read input from shell and mysql password dialog from install package)? And how can i record everything he inputs?

I read about logger, but since there are a lot of commands do i have to log every command or can i just log the whole script.

View 3 Replies


ADVERTISEMENT

Programming :: Sed - Save Output To File With Filename From Content Of Another File?

Feb 28, 2011

My employer issues pdf files with everyones work schedules. I copy the content and save it as plain text in a file called unformatted (hope to be able to automate this step someday). Im working on a SED script that reduces unformatted to only display what I want to see and saves the result in a file Iïve named formatted. After that I have to manually copy formatted and save it with that days date as a filename e.g. 2011-02-25 or whatever day is scheduled in the pdf, for use on a mobile device (Nokia N900). I noticed that the date occurs on certain lines in the file so I added a line like:

sed -n 's/^Date: (201[1-9])/([0-1][0-9])/([0-3][0-9]).*/1-2-3/p' < unformatted >theDate
That creates a file theDate with the date in it that I wish to use as the filename for this particular instance. So I would like to skip the file formatted all together and have the sed- script write to a new file using the content of the Date as a filename, but how do I make that happen? And of course it would be more elegant if I could skip the intermediate theDate file as well.

View 4 Replies View Related

Ubuntu :: Save All Terminal Output To A .txt File?

Mar 15, 2011

I sometimes stick my neck out and provide somewhat detailed, and often risky, "Mr-fix-it" remedies for boot problems. Now, I know it's possible to amend each command with "whatever_command > whatever.txt" in which case it'll place the command output in a file in /home.

But if you're directing someone to run a lot of commands as I did here is it possible to save the output of all commands to a .txt file without amending each command?

Or is it already saved somewhere that I'm not yet aware of? I wouldn't be surprised if the latter were true, I just haven't yet found it

View 4 Replies View Related

Software :: Save Error Output Of A Running App?

Jan 7, 2010

I started a command, it needs very much time. and i have to save the (error-)output. but i forgot it.

is there a way to save the output of a running process? because the process runs over this night and i want to know what did the process do.

View 3 Replies View Related

Software :: Save Output Of Bash File?

Jul 11, 2011

I've shell bash file script and I want to save the output into a txt file.I Know ./bash.sh > output.txt will save the result into a file but i want to add something into a bash file and then when the bash file process completed, it save the result into a file and I don't want that overwrite the output into the old file, I want each time i run it, it save the result into a new file.

View 6 Replies View Related

General :: Show Output On Terminal And Save To A File At The Same Time?

Jul 1, 2010

I am using:

user@unknown:~$ sudo command -option > log

to save the results of "command" to the file "log", but I'd like to also get the result on the terminal, is this possible?

I am using ubuntu 10.04 lts.

View 3 Replies View Related

General :: Save The Output To A Log File Without Wiping The Previous Contents?

Jul 25, 2010

For example, I run a program called "luck" and it outputs a sentence like "good luck". Then "./luck -> logfile" will save the output content to logfile.But when I run another program called "hello" and it outputs a sentence lie " Hello world".Then "./hello-> logfile" will save the output content to logfile and wipe the previous contents.Is is possible to keep both sentences in the logfile? Just like

View 2 Replies View Related

General :: Check The Output Of Assembly File?

Jan 14, 2011

I have a small doubt regarding Assembly file compilation. I have two .s files. When I compile two .s files I am getting corresponding .o files. But when I compare the both .o files with diff command, it is resulting that two files are differing. How could/ what are commands we should use to understand the difference between two .o file's output.

View 4 Replies View Related

Ubuntu Servers :: ERROR Installation Failed, Please Check The Terminal Output

Apr 24, 2010

I'm installing and configuring my first server using RackSpace CloudServers running Ubuntu Karmic Koala (9.10) and I'm now installing iRedMail. The installation runs successfully until I recieve this error:

Code:
The following packages have unmet dependencies: mysql-server-5.0: Depends: mysql-server-core-5.0 (>= 5.1.30really5.0.83-0ubuntu3) but it is not going to be installed

E: Broken packages < ERROR > Installation failed, please check the terminal output. I understand this is telling me there is some software that iRedMail (or something iRedMail is dependant upon) that needs installed. Is this correct? And if so, what is i needing installed and how do I do that (aptitude install example-package?)?

View 4 Replies View Related

Server :: NFS Large File Copies Fail - Error Writing To File: Input/output Error?

Jun 27, 2009

I recently upgraded my file/media server to Fedora 11. After doing so, I can no longer copy large files to the server. The files begin to transfer, but typically after about 1gb of the file has transferred, the transfer stalls and ultimately fails with the message:

"Error writing to file: Input/output error"

I've run out of ideas as to what could cause this problem. I have tried the following:

1. Different NFS versions: NFS3 and NFS4
2. Tried copying the files to different physical drives on the server.
3. Tried copying the files from different physical drives on the client.
4. Tried different rsize and wsize block sizes when mounting the NFS share
5. Tried copying the files via a different protocol. SSH in this case. The file transfers are always successful when I use SSH.

Regardless of what I do, the result is the same. The file transfers always fail after approximately 1gb.

Some other notes.

1. Both the client and the server are running Fedora 11 kernel 2.6.29.5-191.fc11.x86_64

I am out of ideas. Has anyone else experienced something similar?

View 13 Replies View Related

Ubuntu :: Error - Failed To Save File ImageMagick Returned Error Code 11 Command Line

May 1, 2010

simple scan error as follows: Failed to save file ImageMagick returned error code 11 Command line: convert -adjoin /tmp/simple-scan-DA9MBV.jpg /tmp/simple-scan-XCK4BV.jpg /tmp/simple-scan-NZVYBV.pdf Stdout: Stderr: using karmic note: I have apparmor extra profiles installed but didn't notice one that related to simple scan or imagemagick. Red herring or not?

View 6 Replies View Related

Ubuntu :: Error (splicing File: Input / Output) While Copying File

Jun 3, 2010

When I try to copy PDF files from one folder to another folder, it give me this error: "Error while copying "2004-SNUG-Europe-paper_...log_DPI_with_SystemC.pdf". There was an error copying the file into /media/CCDCE66BDCE64F70/Backup Master/Heterogeneous_cosimulation/Documentation" "Error splicing file: Input/output error" What is the reason of this error and how can this be fixed?

View 9 Replies View Related

Ubuntu :: Copying File - Error Reading From File Input/output

Jun 29, 2010

I have a 7.2 GB file (VMWare virtual machine file) that I am trying to copy from its original location to the another folder OR to external hard drive...each time I try to do this, I always get the following error after the copying process reach 'exactly' 1.4 GB

Error reading from file input/output error

And I have to either Cancel or Skip

I've tried to split the files to smaller pieces but the idea didn't work as I still get the same error whenever I try to compress/ split or do any operation with this file. how I can copy this file?

View 2 Replies View Related

Programming :: Find Command With Standard Error Output And Mail Error File

Nov 11, 2010

We make everyday a DB Mysql backup on Linux redhat Enterprise. We are using a bash shell script (and putting it in the crontab) to execute it automatically everyday. We added a line to this script telling, once the backup has completed, to find old backup files (stored on hard disk after each backup) older than x days to remove them. We use the find command (search for file type) with the mtime option and in combination with rm command. Everything runs ok but we also want to add some new code to the same line: If find command cannot find anything or fails, for example if it cannot delete file or fails, send the error message (standard error output) to an error file (like error000001 and increasing) and mail the errorxxxx file to an email address for example to admin@companyname.com. What would be the code for this issue to add it to our find command in the same bash shell script??

View 2 Replies View Related

Ubuntu :: Permissions - Save A File Into The Partition And Get An Access Denied Error

Oct 10, 2010

I mount a partition to a directory and ls -liah tells me that everyone has read/write/execute permissions on the whole thing, but I try to save a file into the partition and I get an access denied error. First of all this doesn't make sense because ls is telling me I do have access.

Then it gets weirder. I run sudo chown -R me:me directory. The command exits without error, but then when I go and look at the directory again with ls, it still shows up as owned by root and I still have the same problem. This is particularly strange because I am still able to change permissions normally in the operating system filesystem. It just won't work on the mounted partition.

View 1 Replies View Related

Ubuntu :: Error - File System Check Failed

Mar 10, 2011

I have a Hp Netbook, and my friend installed Ubuntu to my computer. Everything was going fine, until one day my battery died while I was searching the web. I turned it back on and It started checking files and then it took me to a black screen with white letters saying "File System check failed".

View 3 Replies View Related

Ubuntu :: Scanner - When Try To Save Image To Desktop Or File/folder - Message - Child Process Error

Jan 23, 2011

I have ubuntu 10.04.1 and a H.P.psc 1311 all-in-one printer scanner.Printer works ok but when trying to scan,with xsane,it goes through the scanning process and an image of the document comes up on the screen.

When I try to save this image to desktop or file/folder whatever I get the message; "Child Process Error. Failed to execute OCR command:GOCR:no such file or directory."

View 3 Replies View Related

Ubuntu :: Cannot Open File: Input/output Error

Nov 11, 2010

I just received a 1TB external(Western Digital) hard drive(NTFS) for backup purposes. I'm using an Ubuntu Live CD, and an external hard drive dock. I am transferring over esata and am receiving the error:

Code:

Cannot open file: input/output error

Seems strange that it said "open". At any rate only about 60 of the 200+ GB were able to be transferred over...this won't do. I have tried to copy via CLI using

Code:

cp -r

and received the same issue. For clarification I am attempting to transfer from a mounted partition onto the mounted external.

View 2 Replies View Related

Ubuntu :: 11.04 Update Error Message About File Permissions And To Check Connection?

May 3, 2011

I had to register with a new username, because I could not remember my logon details and have since changed ISP so could not get details sent, anyway that aside to the problem.

I upgraded to 11.04 and all went well (hence posting here and not in the Upgrade section) and it is running fine, well until yesterday.

I ran the update manager as I usually do when first entering Ubuntu and it did an update but then gave me an error message about file permissions and to check my connection (which was connected OK).It has also affected the Software Installer, and now I can not install any new software.

Is this a generic problem with the latest update or is it just my Dell Inspiron 1545 please?

View 1 Replies View Related

General :: Error Occurred During The File System Check

May 18, 2010

i have problem during boot my F11 , the problem is :

Code:

checking file systems
/dev/sda7 : superblock last time ( etc... )
/dev/sda7: Unexpected inconsistency ;run fsck manually (i.e,without -a or -p option)
***an error occured during the file system check
***dropping you to shell:

View 2 Replies View Related

Software :: Error Occurred During The File System Check

Feb 2, 2010

An error occurred during the file system check, dropping you to a shell; the system will reboot when you leave the shell. Give root password maintenance (or type control D to continue)

View 13 Replies View Related

Ubuntu :: Canot Remove File Input/output Error

Apr 8, 2010

I got a new HDD like a Storage on my Ubuntu ,it is formated as ext3 and i am able to mount it ,but sometimes while downloading from FTP ,when the session broke Ubuntu crates some ./afternature.mp4 Input/output error ,which i can see on "ls -l" ,and that causes great troubles to me ,because i can not copy or write on that disk another file with the same one which is created like this ,these error are gone only if i format the hdd .

My mounting command is "mount /dev/hdb3 /tmp/hd ext3 rw 0 0" So is that possible to remove these error without formatting the disk . PS:I did a lot of search for that error ,on unix forums also here but i didn`t find a concrete answer ,i found a thread which is for that case but removing with inode is impossible because on ls -l i`m not receiving the inode .

View 5 Replies View Related

Fedora Installation :: Error It Just Says Check The Log File For More Details And In The /tmp/setupXX.log?

Jan 28, 2009

I am trying to install Fedora-ds on Fedora Core 10 and I am getting a weired error.it just says check the log file for more details and in the /tmp/setupXX.log

[09/01/28:16:01:35] - [Setup] Info Administration port
[09/01/28:16:02:00] - [Setup] Info 9830
[09/01/28:16:02:00] - [Setup] Info The interactive phase is complete. The script will

[code]....

View 4 Replies View Related

Ubuntu Multimedia :: Creating ISO File In Terminal - Input / Output Error

Feb 15, 2011

I'm trying to create an iso file in a terminal with the following command:
$cat /dev/sr0 > nameofdisk.iso
I get the following error
cat: /dev/sr0: Input/output error
I already checked and my optical drive is indeed /dev/sr0. I've hunted google a few hours trying to figure it out. Does anyone know why I'd be getting this error?

View 4 Replies View Related

Fedora :: Cannot Remove `file': Input/output Error

Jan 21, 2011

When running rsnapshot tonight it failed with a bunch of

cannot remove `file': Input/output error

errors.

I navigated to the directory and tried to delete it manually and I got the same errors. I tried with 'sudo rm directory'. How else can I delete this directory? What would cause a situation like this?

View 9 Replies View Related

Slackware :: Error: Checking For C Compiler Default Output File Name

Feb 20, 2010

I downloaded Go-OpenOffice from SlackBuilds.org, but I can't build it. make terminates with configure error: checking for C compiler default output file name. configure: error: in `/tmp/SBo/ooo-build-3.1.1.5': configure: error: C compiler cannot create executables See `config.log' for more details.

(I can't find config.log anywhere) I use a quite 'light' installation (no xap, ap), and I suspect that I have some unmet dependencies, but the error message provides no information about what software is needed (I've installed all dependencies listed on SlackBuilds.org). I'm using Slackware64-13 with Xfce

View 3 Replies View Related

General :: Can't Save Grep Output Into Variable / Solution For This?

Feb 3, 2010

I would like to grep two numbers out of a text file, and divide them.

Here is the script code...

It feels like grep saves a new line too? or what is happening? i simply can't divide them, as it handles the variables as they are empty (and prints the two numbers although they were not printed

View 6 Replies View Related

Slackware :: The Computer Booted Up, But Displayed A Message That Said Something To The Effect Of, "Error Occurred During Root File System Check?

Mar 3, 2010

Started slackpkg upgrade-up and went to bed. Woke up to find the power had gone out during the night. The computer booted up, but displayed a message that said something to the effect of, "Error occurred during root file system check. You will be given the option of doing maintenance......"I can get to a command prompt, but regardless of what I do a message pops saying it can't find libblkid.so.1

View 14 Replies View Related

Ubuntu :: Copy The File Via SSH \ Save The File Via SSH To This Server?

Mar 22, 2011

Now i install the Ubuntu 10.4 64 bit on Sunfire X4170I want to save the file via SSH to this server.But i m not sure how to configure.

View 4 Replies View Related

Fedora :: ERROR 1064 (42000): You Have An Error In Your SQL Syntax; Check The Manual That Corresponds To Your MySQL

Jul 20, 2010

i ,musing mysql5 at fedora12 i have just installed it but i ,m using mysqladmin -p root password mypassword it says ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'mysqladmin -uroot password 123456' at line 1

View 10 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved