Latest Linux and Unix Posts

By now you figured out that without asking what printer to print can't be avoided.

I have discussed this issue with the Network people, and there is no way that the Federal government can require state governments to adopt a standard printer. The Benefit Financial Model( BFM) is run on a server at the National Office, and the state users log in from their state office with Putty to run the BFM. Also the BFM is inside the firewall at the National Office, so the BFM cannot find the printer at the individual state offices. I discussed this with the customer, and the customer agreed to my suggestion that instead of printing, the BFM will email the file to the state user. I have been working on converting the bash script to send email instead of printing, and I am having a problem with the case statement that does the seding of the email. the code that is giving a problem is:

## print or display
    if test $print_flag
    then
      if [ $run = FF ]
      then
        rm -f picktbls
        /bfm/devt/comexec/prtmnu $showfl ##select tables >temp.d
        act=`cat temp.d`
        if [ "$act" = QUIT ]
        then ##canceled
          bfm_sigon
        elif [ "$act" != ALL ]
        then
          showfl=picktbls
        fi
      fi
                case $OPT1 in
                  ARKANSAS)
                    mailx -s "BFM Output" $ARUSER1 < $showfl;;
                  CONNECTICUT)
                    mailx -s "BFM Output" $CTUSER1 < $showfl;;
                  DC2)
                    mailx -s "BFM Output" $DCUSER3 < $showfl;;
                  GEORGIA)
                    mailx -s "BFM Output" $GAUSER1 < $showfl;;
                  INDIANA)
                    mailx -s "BFM Output" $INUSER1 $INUSER2 < $showfl;;
                  KANSAS)
                    mailx -s "BFM Output" $KSUSER1 $KSUSER2 < $showfl;;
                  KENTUCKY)
                    mailx -s "BFM Output" $KYUSER ...

I'm going to upset someone here. After decades of such work, we backup the entire server when it is not "live." We can use any number of methods you find on the web to backup the entire server and have never had to look for software to do this for us as almost every Live Linux on USB, DVD can give us the "dd" command to clone the entire drive. I'm going to skip supplying google searches since you are running a RedHat from the year 2000 and by now you know how to do that work.

But when you ask about converting your physical RedHat 6.x to a virtual machine, RedHat gives GOLD in the instructions at
https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/6/html/v2v_guide/chap-v2v_guide-p2v_migration_converting_physical_machines_to_virtual_machines

I have to ask why anyone would run a server without performing backups on a regular basis. I won't write badly about you but it's always interesting why folk do this.

Hello,

I currently have a RedHat Linux version 6.4 running on a physical server (HP). However, recently it has started to show a failing disk problem, with some failures at software level as well like the terminal not opening properly, and while waiting for a new replacement disk to be made available, I would like to be able to backup a whole image of the server, and eventually run it on VirtualBox or VMWare should the disk fail completely.

Any tool (free preferably) or manual steps which can be useful in my case?

Thanks.

"I am not assured that every state uses the same class of printer."

That's what your IT has to solve with a consistant way to resolve what printer to send to. Think over how they print now. They must know the printer name so maybe this is something you ask for in your script. Or you stump for a standard across the system for a default printer in some environment variable for scripts to use when called. Note: https://docs.oracle.com/cd/E19683-01/806-7612/customize-8/index.html

Thank you for the documentation link, rproffit. Not having the -P option is the big problem I am seeing. However, I also have the issue that each state will be printing these outputs at their own office, not the National office I work at. Therefore, I cannot put a specific printer name in the bash script, since multiple states use the same bash script for running their version of the application. I see from the Oracle documentation that I can specify a class of printers with the -P option, but I am not assured that every state uses the same class of printer. I am not sure of what I should actually be putting as the printer name with the -P option.

 Hello, my name is John McPherson. I work as a contractor for the DOL, and I am trying convert some code I maintain in an application to send output files to a printer. Right now, the code( a bash script) just slowly prints the output file on the screen, and the customer wants to have it sent to the printer instead. I work on a 64-bit Oracle( Sun) system with Solaris 11 as the Operating System. I have tried the command

     lpr -h -l $showfl

in the bash script, but that just errors off without printing. I kept searching online with google search, and found the command

fmt -u -w 200 $showfl | lpr

but that also just errored off without printing. I finally found a Solaris man page on google that listed all of the system commands, and I could not find the lpr or fmt command on the man page. I have to think that Solaris allows the user to send files to the printer, and I am just missing something when I try to update the bash script. Note that in the width specification of my second attempt, I have a large number. That is actually correct, these output files do have a lot of columns, and I am trying force the printer to print the output as landscape, not portrait. I was using the -h and -l options to block printing a banner page, and have the printer just print the output as it was sent. ...

Using testdisk in linux can recover files from bad sectors hard driver

Wow nice video..
For data recovey I usually us Testdisk,foremost or Scalpel in linux
Autopsy or FTK

I wonder if you watched the video and heard the advice not to buy the Deepstar unit but find a shop that would connect it and push the button? That way it's not thousands of bucks.

I find a lot of folk are still not backing up what they can't lose. I see 1TB drives for under 39USD and recovery of what you can't lose costs hundreds. Backups are cheap, recovery is time consuming, not always do it yourself and costly. Usually it takes a big loss for folk to figure this out.

More videos about recovery at:
https://www.youtube.com/watch?v=TIwbndHTp_8
https://youtu.be/tNUsoangGFs

In my town we have those 300 dollar data recovery shops. They have those deepspar units.

DeepSpar is wonderful because it can recover data from bad sector not just skip it but the problem is it's very expensive!

I was unclear. As a rule I don't duplicate the web but share what I'm using and am looking into. That is, I want what I write to be unique and not what you can google. If you want to lookd into ddrescue and bad sector workarounds, check that google I gave above.

But another nod to Deepspar's nearly automatic fixer for drives that delay to register or read badly. Watch that video about it.

Thanks again for answer
The problem is there drive letter for WD unable to detect in windows but shown in Diskmanagment as unallocated disk but in linux show it
I try to reover it unallocate partition with sevral powerful tools but got error becsue of badsector so my solution is just use linux to take an image on WD har driver with bad sector!
So I don't know should I use dd (dd if=/dev/old_disk of=image_file conv=noerror) or ddrescue?
ddrescue take very long time?or mybe there is ddrescue command that save my time!

@tony, I think it is an answer. Over the past few years I've been seeing a lot of iffy drives and been looking for reasons and methods to get the data out.

I forgot to mention another common tool we use. RECUVA. Free and plenty of tutorials on the web.

Adding with edit: I didn't mention anything from https://www.google.com/search?q=ddrescue+skip+bad+sectors

It was really very interesting but it was not answer for my question!

You have asked some very interesting questions plus using the name of a character in a series which is why I wrote that.

https://en.wikipedia.org/wiki/WAV does note metadata in .wav files but also notes that apps have been confused at times when you do that.

I have to write that I would not count on metadata to work in .wav files. You can try but I think this is an area you have to test and see how it turns out.

Yes I'm a FLAC user, if it's a song I really love then .wav is my preference but I prefer most of my music library to be .flac, as such I like to shop for music at https://melodishop.com/

Sorry to be one of your favorite humans.

Why yes it can. And small world I just found a tool via Linustechtips that tackles that issue.

Watch and see what it is at https://www.youtube.com/watch?v=eyr14_B230o&feature=youtu.be&t=549

You may not want to buy that tool but there are data recovery shops that have it.

Hi
I have 500GB WD my passport with bad sector, I try to take disk imaging for forensics investigation with ddrescue but ddrescue was very slowly, is it really take 131d 22h?
Is there any command or way that I can use to speed up ddrescue and just take 8 to 10 hours?
I will appreciate your help.

root@lab:/home/lab/Desktop# ddrescue -d -r 3 /dev/sdc1 WD.dd wd.log
GNU ddrescue 1.22
     ipos:    4980 kB, non-trimmed:        0 B,  current rate:       0 B/s
     opos:    4980 kB, non-scraped:        0 B,  average rate:   57915 B/s
non-tried:  500068 MB,  bad-sector:        0 B,    error rate:       0 B/s
  rescued:    4980 kB,   bad areas:        0,        run time:      1m 25s
pct rescued:    0.00%, read errors:        0,  remaining time:    131d 22h
                              time since last successful read:          0s
Copying non-tried blocks... Pass 1 (forwards)^C

I have to write I think that's how those other apps function. Very few apps agree on what to do with meta data. I see this also is answered "No" and maybe at https://askubuntu.com/questions/131003/rhythmbox-and-metadata

The maybe is for the file types MP3, OGG but not FLAC. Even plugins don't fix this one.

So are you a FLAC user?

This may not be the best room to post this in but I didn't see any room that really jumped out at me for this, and since I'm doing all this on Linux desktop it made sense. I'm having trouble placing the meta data (artists, album, title) for a .wav song that I have. Through using three different programs I'm gettin different results. I can open the file in Rythmbox and select properties for the song and I can see the text fields for all the formentioned meta data above, thie fields all say 'Unknown' and the text fields aren't grayed out or anything but Rythmbox still will not allow me to change any of the meta data, clicking in any of those fields and typing yields nothing. I was able to change the meta data using VLC but VLC is the only application that sees the changed meta data, Rythmbox, Media Player, and my handeld digital music player all see null or Unknown for the meta data. Any ideas on what's going on? Thanks.

commented: "One of my favorite humans." +15

@J, back to armbian developers or their forum to find out if they plan support.

For friendlycore "eflasher" will work(I have tried that).But for armbian it is not detecting the eMMC.

It appears they have their own tool chain. I'm only working the Raspberry's for now but here's the Wiki about their own tools.
http://wiki.friendlyarm.com/wiki/index.php/NanoPi_NEO_Plus2#Flash_OS_with_eflasher_Utility

I have a NanoPi Neo Core with eMMC..I have installed armbian os from "https://www.armbian.com/nanopi-neo/" to sd card and tried the "Armbian configuration utility" and "nand-sata-install" to install os to eMMC. But it is showing "there are no targets..please check your drives."..If we give "fdisk -l" command it is not detecting the eMMC.

How to solve this issue??

If you want to talk distros talk about debian/ubuntu. Almost everyone know those. The others are rare. The best one for newbies is Linux Mint. The best one for computer hackers is Kali. IT people like parrot also.

I agree. You need to explain your question.

That said, "Linux" is a big topic with use being from very small embedded boards, servers, user workstations and what else. The topic is so broad that not only what Linux is being used for matters but what distro you are using along with what issue or topic you want to breach.

Methinks you are going to have to explain that question, as it isn't immediately clear what it is you are asking.

what is the full forum on LINUX?