I have an command to read inputs from file2 and replace the content in file1. Issue is that the op is coming in a single line as gsub and split functions don't recognize new line characters.
Code:
awk 'NR==FNR{gsub(/input./,""); split($0,a," = ");b[a[1]]=a[2];next} {gsub(/@/,"");for (i in b) gsub(i,b[i])}1' $t2 $t3
This gives belwo op:
I'm writing a script that takes the date attribute of a file when it was created and appending it to the name. I'm pretty close to what I need, but the date appears in yyyy-mm-dd format and I want it to read mm-dd-yyyy. What I have done so far is something like
for ((i=1;i<=50;i++)); do fdate=`stat -c %y Video Snapshot $i.png|awk {'print$1'}`; newname=Personname-$fdate-$i.png; mv Video Snapshot $i.png $newname; done
This works decently but the date comes out in the yyyy-mm-dd format. How do I change it?
As I recent convert from Ubuntu to Centos, I have a lot to learn. In Ubuntu, I can plug in a memory stick, run the menu option: System/Adminstration/Partition Manager, highlight the memory stick and choose "Format: Encrypt"
In Centos, my memory stick is /dev/sdc1, how do I, using command line: format it as /ext3, encrypt it using cryptsetup, and set a password?
I've been asked to move data from an old external hard drive to a new one, and to make the new one compatible with the Macintosh. (The old drive's USB connection has died, and I'm connecting to old the drive using a PC card that provieds an eSATA to the drive. The recipient's Macintosh doesn't have a PC card slot, so she can't access the old drive anymore. Hence, the new drive.)
Naturally, I'm doing this data transfer using Linux. I've discovered that I can format the drive as HFS+ using mkfs.hfsplus from the hfsprogs package. But I need to know: do I need to do anything special with the partition table? Is there a special Macintosh partition table format that I need to format this disk to? If so, what tools can I use to get the right format for the partition table?
I bought a 3 TB western digital but I cannot format it. I have to split into 2TB and 1TB (or less because it holds 2.73 TB actually). Is that normal because of linux does not support 3tb yet? I note that I tried into EXT4 and JFS (after tabel creating)
I have a 4 Gb memory stick which used to have OpenSuse on it but I don't use OpenSuse and wanted to use the stick for something else - for backing up my Mozilla Thunderbird installation. I thought that by re-formatting the stick, using a file obtainable from the HP web site, in connection with installing Linux on a memory stick, that it would leave me with an empty one but it hasn't; there is still a lot of OpenSuse stuff on it. How can I "empty" it so that I can use it to transfer my Ubuntu Thunderbird to another computer which is also running Ubuntu. I was going to open a terminal and type:
I tried to format my harddisk (160 GB) with the following command
dd if=/dev/zero of=/dev/sda
After some 3 hours, following error came up:
dd: writing to '/dev/sda' : No space left on device 312581809+0 records in 312581808+0 records out 160041885696 bytes (160 GB) copied, 10708.3 s, 14.9 MB/s
I installed openSuSE 11.3. By default, man pages blocks are justified (block-aligned). Example:
Code:
WARNING Improper use of this command may seriously damage your system,so read this manual carefully to understand how to use it correctly and prevent yourself from destroying your system. Instead, I would like all manual pages would be displayed left-aligned, like this:
Code:
WARNING Improper use of this command may seriously damage your system, so read this manual carefully to understand how to use it correctly and prevent yourself from destroying your system.
I definitely would not like to reformat all the manual pages one-by-one. but rather just changing sometnihg in some macro-definition file or something similar? .. Is it possible achieve that simply and quickly?
I have only known about Linux software for the past couple of weeks. I want to install Ubuntu 10.10 on an older desktop I have so I can become more familiar with it. I am average in knowladge about Windows OS and MS-DOS. I tried to install Ubuntu and I get an error message about the harddrive. The CD I am booting with will load on my other PC with Windows XP on it. I have only let it run on it long enough to verify that it is bootable.
I have made a floppy boot disc following the instructions on another Linux site about Ubuntu. I have also tried to boot my alternate PC with the floppy and it boots up. The harddrive on my working PC is a Maxtor 40gb formatted with NTFS file system. The harddrive in the older desktop is a Western Digital 80GB WD800LB-55DNA0.It worked fine with Windows XP on it. I also made a Western Digital DATA Lifeguard for DOS floppy and it boots with it.
I don't want sympathy, but merely explain what I'm up against. I'm 63 years old. I'm on medical and mental disability (Cognitive failure, the beginning of Alzheimer's). I used to be a good computer tech, but now, because of my memory problems, I don't remember how to do a lot of things with a computer.I'm seeking assistance (not 24/7 help or hand-holding)to help me reformat,partition, and set-up a dual-boot for both WIN 2000 Pro and Ubuntu Linux to operate programs where I can use my Amateur (Ham) Radio in digital modes (PSK-31, PSK-64, BPSK, cw, etc). I'm choosing NOT to run Ham Radio DeLuxe, as it's bloated with M$ "code" and could be hacked and messed with.
The hard drive is a Maxtor 80 gig (78 g formatted). I have another drive,a Western Digital 40 gig (37 g formatted) that I use for Windows as well, but mostly it contains Excel spreadsheets with Part 90 - Public Safety frequency information for the local (within 250 miles) from my home. It's a FAT 32 and I'd like the 80 gig to match that
I'm writing a script that gives me some pertinent info about my servers, and the last little piece I need to figure out is the process list. There are going to be non-technical people looking at the output of the script and I'm trying to make it as simple as possible.
Right now, if I do ps -ef | grep <process> | grep -v grep It obviously shows me the process, but the problem is that there is 4 lines of info in front of the process. ie
root PID date time java -1024 -cp oh,my,god,there,is,so,much,data,it,carries,on,for,4,lines,I,want,to,shoot,myself,trying,to,read,it,f inally,in,the,end,there,is,a,space /here/is/the/process I'd like the output to be something like this: PID: #### Process: /here/is/the/process
I've thought about how I could take the output and use awk or sed but I know there is probably an easier way to do it with perl.
I have a 16GB memorystick which used to have a Linux partition. It therefore has two partitions; 2GB FAT32 and 14GB linux boot drive. The linux part stopped working, so I decided to reinstall it. But windows can't see that partition. I tried formatting the whole disk, but I can only format one partition (the FAT32). There seems to be no way to combine the two partitions into one big one, and there seems to be no way for windows to partition the large part of the memorystick to but Linux on it. In the windows partition manager, windows sees the large unused partition, and it let me delete it. But once I have deleted it, I'm not allowed to format it. Also I cannot delete or resize the small partition. I have a memorystick with two partitons. Windows only sees one of them, and won't let me use the other one. I would like to combine the two partitions so I can install Linux on the memory stick again.
I'm a big fan of the NSLU2-Linux project so I've been doing some developments for this platform for the last three years. In order for the end users to test my applications, I initially created an USB image with everything bundled into it. Then, they only had to download the image and decompress (dd) it into an USB pendrive with capacity equal or greater than 4 GB. The fact is that this has brought me lots of problems in the practice since my Web server hardly accepts long file transfers.
Moreover, flash spaces beyond 4GB are wasted. As result, I'm now considering a different approach as I don't know how to do it. Well, I've thought that I could maybe create an USB disk image only with the root file system partition. Then, the first time a script runs, it creates a home partition and formats it into the rest of the space available in the pendrive. There is maybe some command-line alternative to fdisk without having the user to interact during the format process... ??
I have a computer that was given to me and is no longer booting up properly. It's an Acer with VISTA installed. I would like to format the hard drive and start over with Linux. I don't have the original windows vista disk, I don't believe the computer even came with one, and no back up disks. Apparently this is the only way to format VISTA. When I am in the command prompt here is what happens.
C:> format c: The type of the file system is NTFS. Enter correct volume lable for drive C: I don't know the correct label.
Searching on the forums I found this. format c:/fs:NTFS/p:/ That doesn't work. I get this: "Invalid parameter - /p:"
How can I format a USB hard drive to ext3/ext4 or whatever file format and have full permission to read, write and execute all files afterwards? When using the command line (as ROOT of course) mkfs.ext3 /dev/sdb? Restricts the rights to ROOT as does the procedure gParted. The man mkfs did not help much. Configuring the fstab- file is a bit of a hassle, so it would be nice, if there was an option to set the permissions "correctly" right from the beginning. Setting Ubuntu (I'm using Ubuntu 9.10) up, so that it mounts USB devices not as ROOT as default but giving all users all permissions seems to be really complicated, as a guy from my local LUG told me.
I was using Win Xp ,and i installed Ubuntu ,I used to get an option to select windows or Ubuntu before,I formatted Windows and now am not able to find the grub menu where iI could select Ubuntu,.How to get the grub enabled?
In vmware workstation 6/7 (using windows xp as host), how can I map virtual disk of my linux VM? When I try to map it, it maps but when I try to explore it, it gives me an error of formatting!
I have a question about viewing HTML emails in the Evolution mail client. Basically, I am receiving some emails that look lovely in Thunderbird but not in Evolution because the HTML rendering of Evolution isn't as advanced.Here is a screenshot of the difference: how to improve the HTML rendering of Evolution? e.g. a plugin, tip, code patch, etc. The closest I've got is to right-click the email, "Save As...", save as a html file, then open in Firefox. Not exactly streamline!What emails can't it display well? We use the subversion revision control system which is set up to send an email whenever someone commits via svnnotify all nicely coloured via the --handler HTML::ColorDiff -d parameter. When Evolution fails to use the colours, I find it very hard to read the raw diff.
I have a server running an older version of Ubuntu and with /var stored on a separate partition on a separate hard drive. I am attempting to update Ubuntu to 10.04, but I still want to store /var on a separate partition and hard drive. However, I don't want to format the drive which currently contains /var, as it has important data.
Is there some way to have 10.04 set up the new /var on this separate drive at installation, without formatting the drive and losing the old /var?
I have just purchased a 2TB drive for my server and I was trying to get an idea of the differences between these file systems or other file systems out there. What is the amount of space after formatting for ext4, ext3, and ntfs?
I am wondering if any of you technical guys would be willing to format my Western Digital external USB 1.5 TB Hard Drive to Linux EXT3. I am naturally happy to pay for your time and trouble and for postage. The WD drive is for storing video footage and will be connected to my Humax Freesat HD Digital TV Box(not a computer), and the Humax Box will only record high deffination programmes in EXT3 format. I've tried to do the job myself with my PC, but have failed to change my system to format in Linux.
I have a Western Digital My Book World Edition external harddisk with blue rings. I filled it up and now want to delete the data and start over. I'm set in my ways and have been accustom to reformatting harddisks periodically (sector maintainance, etc.) It's worked for me as I've luckily have not had a disk crash in 25 years.My webapp is not helping me with the reformat and neither is Western Digital tech support. I've heard that it was factory formatted with something called Linux ext3. Does this make sense? Has anyone had any experience with reformatting external harddisks being used as a NAS (home use).
I installed win 7 and Linux Mint, however I've now decided to uninstall both and start with a fresh hdd. Anyway formatting went fine and started installing win 7 however there was a reading error from cd and canceled. Now ever time I try and start my pc it comes up with error: unknown filesystem and the grub rescue prompt. Now I don't know what to do as i can't seem to get around this and back to win 7 installer.