LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Debian
User Name
Password
Debian This forum is for the discussion of Debian Linux.

Notices


Reply
  Search this Thread
Old 03-16-2018, 12:27 AM   #1
pedros
Member
 
Registered: May 2017
Posts: 85

Rep: Reputation: Disabled
dd problem.


This data is for debian 9.3. However, I remember seeing the problem
with other debian versions and with other hardware systems.
I copy each dvd of the debian software repository from physical dvd media to iso file in a previously created path. I run one line of code at a time, and insert corresponding dvd each time.$
Code:
dd if=/dev/sr0 bs=1M of=/os/debian/9.3.0/amd64/DVD/iso/01.iso
dd if=/dev/sr0 bs=1M of=/os/debian/9.3.0/amd64/DVD/iso/02.iso
dd if=/dev/sr0 bs=1M of=/os/debian/9.3.0/amd64/DVD/iso/03.iso
dd if=/dev/sr0 bs=1M of=/os/debian/9.3.0/amd64/DVD/iso/04.iso
dd if=/dev/sr0 bs=1M of=/os/debian/9.3.0/amd64/DVD/iso/05.iso
dd if=/dev/sr0 bs=1M of=/os/debian/9.3.0/amd64/DVD/iso/06.iso
dd if=/dev/sr0 bs=1M of=/os/debian/9.3.0/amd64/DVD/iso/07.iso
dd if=/dev/sr0 bs=1M of=/os/debian/9.3.0/amd64/DVD/iso/08.iso
dd if=/dev/sr0 bs=1M of=/os/debian/9.3.0/amd64/DVD/iso/09.iso
dd if=/dev/sr0 bs=1M of=/os/debian/9.3.0/amd64/DVD/iso/10.iso
dd if=/dev/sr0 bs=1M of=/os/debian/9.3.0/amd64/DVD/iso/11.iso
dd if=/dev/sr0 bs=1M of=/os/debian/9.3.0/amd64/DVD/iso/12.iso
dd if=/dev/sr0 bs=1M of=/os/debian/9.3.0/amd64/DVD/iso/13.iso
dd if=/dev/sr0 bs=1M of=/os/debian/9.3.0/amd64/DVD/iso/14.iso
I check the iso files with MD5SUMS. The first and last iso files are always good. However, the other iso files are usuially corrupt.
To make all the iso files good, I restart the system after each run.
Note that the iso files are all about the same size, except
the last one, which is smaller.

when system starts up, message says watchdog did not stop!
Here is some information I found about watchdog.
systemd sets a "hardware watchdog" timer as a failsafe, to ensure that if the normal shutdown process freezes/fails that the computer will still shutdown after the specified period of time. This time period is defined in the variable ShutdownWatchdogSec= in the file /etc/systemd/system.conf.
#RuntimeWatchdogSec=0
#ShutdownWatchdogSec=10min

So, how can I create the iso files, without restarting the system after each one? And what is causing this to happen?
For more details, see pdscript.com/d9316.txt.
 
Old 03-16-2018, 07:05 AM   #2
pan64
LQ Addict
 
Registered: Mar 2012
Location: Hungary
Distribution: debian/ubuntu/suse ...
Posts: 21,892

Rep: Reputation: 7317Reputation: 7317Reputation: 7317Reputation: 7317Reputation: 7317Reputation: 7317Reputation: 7317Reputation: 7317Reputation: 7317Reputation: 7317Reputation: 7317
Probably the dvd was auto-mounted. Probably you can find some related messages in /var/log.
 
Old 03-16-2018, 05:33 PM   #3
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 21,130

Rep: Reputation: 4121Reputation: 4121Reputation: 4121Reputation: 4121Reputation: 4121Reputation: 4121Reputation: 4121Reputation: 4121Reputation: 4121Reputation: 4121Reputation: 4121
I would say you are pulling the disk out before it's finished writing. Add " && sync" (leading blank) after each command, theat way the prompt won't return until the write is complete.
 
1 members found this post helpful.
Old 03-17-2018, 05:12 PM   #4
pedros
Member
 
Registered: May 2017
Posts: 85

Original Poster
Rep: Reputation: Disabled
Does auto-mount have anything to do with this? Should I change a setting? I found many messages in /var/log. Can you be more specific? And after each run of dd, I carefully checked the terminal for the ending prompt stretch@debian:~$. But you say that does not necessarily mean the write is complete? And there were no error messages in terminal. I think it is unlikely that in 12 out of 14 runs, I pulled the disk out before it's finished writing. But I admit it might be possible. That sounds like a good idea, Add " && sync" (leading blank) after each command. I might try it next time. Any more ideas? Anyone willing to test? Most of the dvds I used are 4.7gb. I suspect any dvd will work as a test, if you have the MD5SUM for it.
 
Old 03-18-2018, 03:56 AM   #5
pan64
LQ Addict
 
Registered: Mar 2012
Location: Hungary
Distribution: debian/ubuntu/suse ...
Posts: 21,892

Rep: Reputation: 7317Reputation: 7317Reputation: 7317Reputation: 7317Reputation: 7317Reputation: 7317Reputation: 7317Reputation: 7317Reputation: 7317Reputation: 7317Reputation: 7317
I'm really sorry, we cannot test it for you. It is exactly you who made a mistake, and you need to find it.
Yes, if you mount a drive (dvd, usb, whatever), some of the filesystem info will be kept in memory. But probably not related to your problem.
Yes, probably dd writes into a cache and you will get the prompt back before the write really completed. That is normal in linux.
you need to check messages related to the dvd device, you can use grep dev.sr0 to find them (for example).
If md5sum did not match the content of the dvd is corrupted. Either because of it was not completely written or because of some "other" things was "remembered" and saved...
 
Old 03-28-2018, 02:08 PM   #6
pedros
Member
 
Registered: May 2017
Posts: 85

Original Poster
Rep: Reputation: Disabled
Next time I do this, maybe I will try something different.
 
Old 03-28-2018, 10:21 PM   #7
rknichols
Senior Member
 
Registered: Aug 2009
Distribution: Rocky Linux
Posts: 4,780

Rep: Reputation: 2213Reputation: 2213Reputation: 2213Reputation: 2213Reputation: 2213Reputation: 2213Reputation: 2213Reputation: 2213Reputation: 2213Reputation: 2213Reputation: 2213
Quote:
Originally Posted by pan64 View Post
Yes, probably dd writes into a cache and you will get the prompt back before the write really completed.
The dd command normally does a sync() before exiting. You can see this when zeroing a slow device like a USB flash drive. You'll see the "no space on device" message from dd, and then a delay (sometimes several minutes) before the next command prompt. The delay depends on the speed of the device and how many gigabytes of buffer remain to be flushed out.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
UEFI problem, GRUB2 problem, blank screen problem, :( JackDinn Linux - Newbie 22 05-26-2015 01:57 PM
Do I have a path problem, an Apache2 problem or a Javascript problem or any other pro rblampain Linux - Networking 0 12-29-2010 03:50 AM
Sound Card problem(every time i install linux i have diffirent hardware problem) jacka1l Linux - Newbie 7 08-11-2005 06:10 AM
Lan configuration problem - NFS boot problem - RX&TX packets errors 242VDM242 Linux - Networking 4 11-25-2004 01:35 PM
perl problem? apache problem? cgi problem? WorldBuilder Linux - Software 1 09-17-2003 07:45 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Debian

All times are GMT -5. The time now is 03:13 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration