might also try dcfldd, it has some enhancements over regular dd....<br><br><div><span class="gmail_quote">On 7/13/06, <b class="gmail_sendername">Rick Stevens</b> <<a href="mailto:rstevens@vitalstream.com">rstevens@vitalstream.com
</a>> wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">On Wed, 2006-07-12 at 19:48 -0700, Harold Hallikainen wrote:<br>> > On Tue, 2006-07-11 at 20:22 -0700, Harold Hallikainen wrote:
<br>> >> Thanks to the help from this list, I now have FC5 running on my HP<br>> >> zv6000<br>> >> AMD64 laptop. Next trick is to make a backup so I don't mess things up.<br>> >> Based on suggestions from the list, I'm trying out g4l. I'm making an
<br>> >> image on a USB hard drive. This seems to work, but I suspect the image<br>> >> is<br>> >> larger than it needs to be because I didn't clear out the unused space<br>> >> on<br>> >> the laptop drive. g4l comes with a simple script to write nulls to the
<br>> >> drive, then delete the created file. The script is:<br>> >><br>> >> dd if=/dev/zero of=/0bits bs=20M<br>> >> rm /0bits<br>> >><br>> >><br>> >> When I run it as root, I get the following errors:
<br>> >><br>> >> ./CleanDrive.sh<br>> >> ./CleanDrive.sh: line 2: dd if=/dev/zero of=/0bits bs=20M: No such file<br>> >> or<br>> >> directory<br>> >> ./CleanDrive.sh: line 3: rm /0bits: No such file or directory
<br>> >><br>> >><br>> >> Ideas?<br>> ><br>> > When you say "I run it as root", did you "su" or "su -"?  You MUST use<br>> > "su -", as "dd" is in /bin and that's not part of a regular user's PATH.
<br>> ><br>> > "su" only changes your UID/GID to root.  "su -" also gives you root's<br>> > environment (including root's PATH).  Alternately, you could change the<br>> > script to "/bin/dd if=...." (in other words, specify the full path to
<br>> > dd).<br>> ><br>><br>><br>> Thanks! I always wondered what the - did. I just used su. Anyway, I did su<br>> - and fully specified the path to dd and it still seems to have<br>> problems...
<br>><br>> [root@hhlaptop Desktop]# ./CleanDrive.sh<br>> ./CleanDrive.sh: line 2: /bin/dd if=/dev/zero of=/0bits bs=20M: No such<br>> file or directory<br>> ./CleanDrive.sh: line 3: rm /0bits: No such file or directory
<br>> [root@hhlaptop Desktop]#<br><br>Hmmm, works for me.  You should specify a "count=" parameter as well.<br>Example:<br><br>[root@prophead work]# dd if=/dev/zero of=/0bits bs=20M count=1<br>1+0 records in<br>
1+0 records out<br><br>[root@prophead work]# ls -lh /0bits<br>-rw-r--r--  1 root root 20M Jul 13 11:31 /0bits<br><br>So, if your script is EXACTLY what you said it is, try adding the<br>"count=" thing to the end.  Also verify that you indeed have the /bin/dd
<br>program and that the /dev/zero device exists.  It should look something<br>like this:<br><br>[root@prophead work]# ls -l /bin/dd<br>-rwxr-xr-x  1 root root 34540 Jul 25  2005 /bin/dd<br>[root@prophead work]# ls -l /dev/zero
<br>crw-rw-rw-  1 root root 1, 5 Jun 21 05:12 /dev/zero<br><br>Note that the /bin/dd program comes as part of the "coreutils" RPM.<br><br>----------------------------------------------------------------------<br>
- Rick Stevens, Senior Systems Engineer     <a href="mailto:rstevens@vitalstream.com">rstevens@vitalstream.com</a> -<br>- VitalStream, Inc.                       <a href="http://www.vitalstream.com">http://www.vitalstream.com
</a> -<br>-                                                                    -<br>-   You possess a mind not merely twisted, but actually sprained.    -<br>----------------------------------------------------------------------
<br><br>_______________________________________________<br>Redhat-install-list mailing list<br><a href="mailto:Redhat-install-list@redhat.com">Redhat-install-list@redhat.com</a><br><a href="https://www.redhat.com/mailman/listinfo/redhat-install-list">
https://www.redhat.com/mailman/listinfo/redhat-install-list</a><br>To Unsubscribe Go To ABOVE URL or send a message to:<br><a href="mailto:redhat-install-list-request@redhat.com">redhat-install-list-request@redhat.com</a>
<br>Subject: unsubscribe<br></blockquote></div><br>