Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

How to make ISO Image File under Linux system

2025-01-18 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

Shulou(Shulou.com)06/01 Report--

This article mainly introduces "how to make ISO image files under Linux system". In daily operation, I believe many people have doubts about how to make ISO image files under Linux system. Xiaobian consulted all kinds of information and sorted out simple and easy operation methods. I hope to answer your doubts about "how to make ISO image files under Linux system"! Next, please follow the small series to learn together!

1. Verify the MD5 value of the downloaded ISO image:

$ md5sum download.iso

2. ISO burning:

1)Download CDRecord:

$sudo apt-get install cdrecord

2)Looking for a device (burner):

$ cdrecord --scanbus (this gives a set of numbers like:0,0,0)

3)Start burning:

$ cdrecord dev=0,0,0 download.iso

3. Check the md5 value of the burned CD:

(Make sure isoinfo is installed if not apt-get~~~)

$ isoinfo -d -i /dev/cdrom

(Check the disc information and the following words will appear: Logical block size is: 2048 Volume size is: 339344)

$ dd if=/dev/cdrom bs=2048 count=339344 conv=notrunc,noerror|md5sum

Making ISO Mirrors

===========

mkisofs -J -T -R -V volume_id -o mycd.iso source_dir

mkisofs Main parameters:

-J/-joliet Directory and file names using Joliet format

-T/-translation-table Generates a TRANS.TBL file name conversion table file for each directory

-R/-rock using Rock Ridge Extensions

-V/-volid Specifies the label ID of the disc

Making CD with self-checking function

==========================

ISO files may change during network transmission, which can be detected by MD5 check code to detect the integrity of the file, that is: release ISO at the same time also publish its MD5 check code, so that others download ISO, and then MD5 operation, if the MD5 value obtained and provided the same, ISO files and original files exactly the same, otherwise you have to download again.

After burning an ISO to a CD, how do you verify that the contents on the CD are exactly the same as the original ISO? Because in the burning process, maybe... There may be mistakes.

This requires the use of isomd5sum.

Add MD5 verification information:

implantisomd5 --force ISO file

After burning, you can verify data integrity by checkisomd5 --verbose

ISO production complete script (with MD5 verification)

Script Run Parameters

mkiso.sh

#!/ bin/sh

#****************************************************

# Author: Muddyboot - toobyddum@gmail.com

# Last modified: 2007-09-11 21:21

# Filename: mkiso.sh

# Description: script for easy creating ISO image

#****************************************************

if [ $# -lt 3 ]; then

echo -e "\nUsage: `basename $0` source_dir output_iso cd_label \n"

exit 1

fi

source=$1

output=$2

label=$3

### extra mkiso argument

shift 3

for i in $@; do

extra_args="$extra_args $1 "

shift

done

if [ ! -e "$source" ]; then

echo -e "\nERR: Source file or directory does not exist ! \n"

exit 1

fi

## remove exists TRANS.TBL files

if [ -d "$source" ]; then

find $source -name TRANS.TBL | xargs rm -f

fi

###Creating ISO

mkisofs -J -T -R $extra_args \

-V $label -o $output $source

###Add MD5 verification information

MD5_CHECKSUM=`whereis implantisomd5|awk -F': ' '{print $2}'`

if [ -z "$MD5_CHECKSUM" ]; then

echo -e "\n** WARNING: implantisomd5 not found, no md5sum added.\ n"

else

echo -e "\n** Good, implantisomd5 program found. "

echo "Adding md5sum information for ISO image ... "

implantisomd5 --force $output

fi

echo

echo "** ISO image $output created successfully ! "

echo

At this point, the study of "how to make ISO image files under Linux system" is over, hoping to solve everyone's doubts. Theory and practice can better match to help everyone learn, go and try it! If you want to continue learning more relevant knowledge, please continue to pay attention to the website, Xiaobian will continue to strive to bring more practical articles for everyone!

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Servers

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report