General :: Sed Adds A Space Instead Of Tab At End Of Line

Jan 14, 2011

The objective is to read a file line by line, add a tab at end of each line and add a value(number) after the tab.

My script:

Code:

Report.tsv before running the script for the first time:

Code:

At the end of first run, each line of Report.tsv gets appended by a space instead of a tab. On the other hand each line of Report.tsv gets appended by tab at the end of second run onwards.

This was realized when Report.tsv was imported in open office spreadsheet. First set of appended values get merged into the original column (Strings) and the subsequent appended values fall in distinct columns.

View 12 Replies


ADVERTISEMENT

General :: Head Adds Chars To End Of Each Line (Red Hat Enterprise)

Apr 5, 2010

I wrote a bash-script that splits each of many .sql-files into two parts by some condition using head utlity. After that I execute all the scripts in sqlplus, and in one or two of them I get an error: SP2-0042: unknown command ")" - rest of line ignored. If I open the file with vi, I can see that in the end of each line there's a "^M", which is treated as a single character. If I delete this character placed before the closing parenthesis, the scripts executes without any errors. In the initial script opened by vi there's no such characters. Is it a problem with the head utility or with something else? Of course, I cannot grep these special chars.

View 13 Replies View Related

General :: Find The Position Of The First Space In A Line?

Aug 8, 2011

I am trying to edit a large bunch of files. Each file has four columns and I want to get rid of the first one, but in each line the number of the first column changes. the number in the first column ranges from 1 digit to 5. For example

1 aaaaa bbbbbb ccccc
23 aaaaa bbbbbb ccccc
15343 aaaaa bbbbbb ccccc

and the desired format would be

aaaaa bbbbbb ccccc
aaaaa bbbbbb ccccc
aaaaa bbbbbb ccccc

View 2 Replies View Related

General :: List Output In Single Line (space Separated)?

Feb 1, 2011

got a situation where if i process a command i get a numeric output something like below:

for example:

# cat example.txt
856589
856470
987866
656658
876897

now i want to see this output in single line like below:

856589 856470 987866 656658 876897

how do i get this?

View 10 Replies View Related

General :: Division Of Logical Memory Space In To User Space And Kernel Space

Jan 4, 2010

Logical Memory Space of 4GB is divided in to 3GB User Space and 1GB Kernel Space. Always. Correct?

1. How can we change it? (just changing value of PAGE_OFFSET is okay?)

2. If system have only 256MB of memory (embedded system) and suppose Kernel Modules eat away all the memory during boot. User space will be left will no memory. Is this case possible?

View 2 Replies View Related

General :: Configure X And Adds Fonts To Its Window System?

Aug 9, 2010

I'm having some difficulty to confgure the windows X manager...

I can't find /etc/X11/xorg.conf

I'm trying to do this in opensuse 11.1 and fedora 12

I tried to install in fedora yum install system-config-display but I think that isn't the best thing to do...

And can anyone tell me a distribution that use XFree 86.4.4.x?

Opense suse, Fedora and Ubuntu use X.org-X11 isn't it?

View 10 Replies View Related

General :: .bashrc File Adds A Couple Of Tens Of Spaces To The Prompt?

Sep 3, 2010

I got myself a .bashrc file off the net. I checked it beforehand, didn't detect anything bad about it. One thing that's odd about it, is that several spaces are added to the terminal command line.Screenshot:Those spaces are not put there by me. The file can be found here: [URL]..

View 3 Replies View Related

General :: Cp Adds Exclamation Points When Copying Very Large Text Files?

Jul 13, 2009

For my research I have some very large files that are basically millions of lines of ten columns of numbers. These files can be up to 5 GB in size. Recently I noticed that when I made a copy of one of my files, some exclamation points appeared in it where there should not be any: in front of random numbers throughout the file. Making another copy of the file would result in exclamation points in front of different numbers in different parts of the file. Doing this many times has given me up to four exclamation points in different parts of the file. Sometimes the file copies just fine without producing any extraneous exclamation points.Additionally, I have occasionally seen a "^K" where there should be a newline (the data that should have been on the next line was instead on the previous line with a ^K in front of it) in copies that I have made of my files. I don't know if this is related or not.

View 7 Replies View Related

Programming :: Disable Irq Line From User Space?

Jul 14, 2011

I have written a device driver and I would like to disable an interrupt. In kernel space there is a function called "disable_irq(int irq)", but, is it possible to do it from user space?

View 7 Replies View Related

Ubuntu :: Quickly Add Swap Space Over Command Line?

Mar 7, 2010

Working with a scientific code that uses more RAM+swap then i generally have (system has 12GB RAM + 24GB swap, but this thing is crazy)It's kind of a one use problem, so I'm not looking to get more RAM, is there a quick way to add more swap space (not on the swap partition, because i have that set at 24GB) so that my system can use it immediately?I don't want to drive up to the office tonight to get this fixed, so a command line setup would work best.

View 7 Replies View Related

General :: Shell Script That Adds Users Name To A File When The File Is Modified?

Mar 30, 2010

I need a shell script that will add the users name and date to a file when the user has modified the file, these files are within a group and only accessible to this group. But we need a way for people in the group to know who and when the file was last modified.

View 1 Replies View Related

General :: Calling User Space Callback Function From Kernel Space?

Sep 22, 2009

I am writing device driver in which i have to call callback function from kernel space, which are saving my data. But the callback functions are in userspace. While accessing them i am getting segmentation fault.

View 1 Replies View Related

General :: Scripting - Cp A List Of Files Which Starts With - Or Space Without - Or Space?

Oct 14, 2009

I have a list of files in a directory which starts with - or have space.

I need to copy them back without the space or -?

linux1[sim]% ls linux1[sim]% cp ./-* ./*

View 8 Replies View Related

General :: Virtual Space Seen By Each New Process In User Space?

Jun 21, 2010

In a 32-bit system, max memory addressable is 4GB. Now Linux kernel does memory mapping division of 1GB for kernel address space and 3GB for user address space. That means 4GB of virtual address space is divided between kernel (1GB) and user (3GB).

Q1. All virtual mapping utilizes the available physical RAM without any division? I mean to say that if RAM is 512MB then a page in kernel space can lie any where RAM (leave aside old PCI dma accesses)? (How this fits to fact that kernel memory is non-pageble)

Q2. If a process is created in user space, it has visibility 4GB address space or 3GB address space?

View 2 Replies View Related

General :: Use Free Space To Extend The Space Of A Drive?

Jul 5, 2011

My system is dual boot with win7 and ubuntu. I have free space of around 10 gb. I want to add this free space to my ubuntu drive. How can i do that?

View 4 Replies View Related

Debian :: 6.0.1 Adds Any New Kernel?

Mar 21, 2011

I know that default kernel for Debian 6.0.0 is 2.6.32-5. Does Debian 6.0.1 add any new kernel compared to Debian 6.0.0?
Where can I find the related information?

View 4 Replies View Related

OpenSUSE :: Way To Block Adds In Firefox

Apr 8, 2011

I'm getting a pesky add in a page. I can block the images, but then I get
an empty window from them. That is not it, I want to block everything from
them.

http://adserving.cpxadroit.com/*

Is there a way?

They load a flash from their clients, which I have to kill one by one, but
it loads another one.

Perhaps block the name in the DNS?

View 9 Replies View Related

Server :: Sendmail Adds MX Record To Addresses

Nov 1, 2010

Im working with virtuals machines to configure Sendmail on Linux.

I work with two domains (ar and org), the configuration is similar in both, so i will write just one.

In orgs mail server:

The emails stopped coming and the server adds to the e-mail addresses the MX record. For example, if i send an email to u1@org in log appears u1@org.mail.org.

View 14 Replies View Related

Software :: Grub Sometimes Adds Memtest Lines?

Apr 1, 2011

Using Ubuntu 10.10 and Win XP - dual drives booted by GNU Grub version 1.98 +20100804-5ubuntu 3 Every now and then, a "Memory Test (memtest 86+)" and a "Memory Test (memtest86+, serial console 115200)" line are added to my Grub startup screen. This causes Grub to start-up a different line than I have set to default. (Ubuntu vs. Windows, etc.)

1. How do I edit the start-up Grub to remove the "memtest" lines?

2. How do I prevent this from occurring?

View 5 Replies View Related

Ubuntu :: Remove Adds One Keyboard Layout At Every Login?

Nov 28, 2010

I installed Ubuntu with the Swedish Eliminate Dead Keys layout as my standard layout. On my own user account I changed the keyboard layout to Swedish Dvorak. I removed the Swedish Eliminate Dead Keys layout on my account. So far so good. But on every login Ubuntu adds the Swedish Eliminate Dead Keys layout again. It's a bit annoying. how to remove it?

View 2 Replies View Related

Networking :: Adds MAC Headers To The TCP/IP Packets - Hardware Or Software?

Mar 20, 2010

Who adds MAC headers to the TCP/IP packets. IS it hardware or software? If you look into TCP/IP packets the first part of the packet is MAC headers. so who adds this MAC headers to the packets? is it the network card or Software(could be OS or anything other than hardware)?

View 7 Replies View Related

Server :: Samba Adds Execute Flag To All New Files

Jan 19, 2010

We have started using ACLs on our fileserver and we are having a problem with getting Samba to behave correctly. When we create a file in Linux, the permissions and ACLs are set correctly. Files are set to 640 and directories are set to 750. However, when we create it in Windows through Samba, regular files are being set with 650 and directories are set to 770. It's adding execute on files and execute+write to directories for groups.

View 2 Replies View Related

General :: Add / Of 3000mb In The Remaining 20380mb Free Space It Showing An Error Message That No Free Space Is Available

Jul 25, 2010

I have 160gb laptop. i installed vista in c primary partition which is 25gb and installed ubuntu in d primary partition which is 20gb. A remainig for my data. Now i tried to install CENT OS by formatting ubuntu. I inserted CENT OS DVD and restarted and i selected to delete my /dev/sda2 which is showing 20480mb and it shown me free space. but i tried to add partion /boot of 100mb it got added. but, when i am trying to add / of 3000mb in the remaining 20380mb free space it showing an error message that no free space is available.

View 4 Replies View Related

General :: Getting Backslash+space Instead Of Just Space?

Jul 26, 2010

I just mounted my drobo(NTFS) on my slackbox using NTFS-3g, and I can read all my files and see them all, but any file name with a space in it turns into EX: (File Name)... instead of (File Name)I am worried that my Sync software will not recognize the name.Does anyone have any tips Except to not put Spaces in the names of files?

View 3 Replies View Related

Ubuntu Installation :: 10.04 Upgrade Adds Unwanted Keyboard Shortcuts

Apr 30, 2010

I just upgraded to 10.04, all went well, except now the "s" and "m" keys on my keyboard open the login menu and the "Me" menu (with the mail and chat options) respectively. Obviously this is very irritating, I can only type those letters by holding down alt. I can't think of how this happened, it didn't do it before the upgrade. I'm using an Apple aluminum keyboard with a Dell. When I run xev and type the s or m key, I get this:

[Code]....

There are no relevant shortcuts under keyboard shortcuts. I am using a xmodmap file that looks like this:

clear mod1
clear mod4
keycode 133 = Alt_L
keycode 134 = Alt_R
keycode 64 = Meta_L
keycode 108 = Meta_R
[Code]....

View 9 Replies View Related

Ubuntu Servers :: Postfix Adds Trailing Slash To Users?

May 11, 2011

I followed this tutorial to setup a mail server, followed it to the letter, double/triple/quadruple checked everything for human error, and I can't find anything.[URL].. What's happening is it seems that postfix is adding a trailing slash to usernames when it does the user lookup, so they don't exist and then fail. I've attached the log below.

Code:
May 11 01:06:27 vmail postfix/smtpd[1688]: connect from localhost[127.0.0.1]
May 11 01:06:55 vmail postfix/smtpd[1688]: 3372E982BC: client=localhost[127.0.0.1]
May 11 01:07:18 vmail postfix/cleanup[1691]: 3372E982BC: message-

[Code]...

View 1 Replies View Related

Hardware :: Ubuntu Recognizes Printer - Adds To The Queue - But Nothing Prints

Aug 10, 2010

I'm using Ubuntu 10.04, and I have an HP D1660 printer. The printer has already been added, and HPLIP is installed. I can't get anything to actually come out of the printer, even though I can send a job to the printer. Does this have anything to do with CUPS?

Here are some of the last error log messages after using the printer troubleshooter (I only included some because it's a long list):

View 1 Replies View Related

General :: Create Cron Tab When DSL Line Down Set Automatically Restart The Network Service While DSL Line Up?

Oct 7, 2010

How to create cron tab when DSL line down set automatically restart the network service while DSL line up?

View 3 Replies View Related

General :: Getting The Line Of String From Previous Pipe Output By Line Number?

Feb 8, 2010

After running the following command, I get:

[root@yukiko /]# find / -iname .bashrc
/home/clamav/.bashrc
/home/vpopmail/.bashrc
/etc/skel/.bashrc
/root/.bashrc

But I would like to have a command that prints a specific line by supplying the command with the line number, for example:

[root@yukiko /]# find / -iname .bashrc | getline(2)
/home/vpopmail/.bashrc

Is there such a command on CentOS?

View 3 Replies View Related

General :: Script To Count # Of Chars Per Line - If Line Meets Certain Criteria - And Get Avg #?

Sep 11, 2009

I have several files with many lines something like this:

I'm trying to write a script that will count the number of characters per line that doesn't contain a ">" symbol and give me an average of those values. I have most of the script together but I can't figure out how to connect some of the steps.

Code:

View 3 Replies View Related







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