LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General > LinuxQuestions.org Member Success Stories
User Name
Password
LinuxQuestions.org Member Success Stories Just spent four hours configuring your favorite program? Just figured out a Linux problem that has been stumping you for months?
Post your Linux Success Stories here.

Notices


Reply
  Search this Thread
Old 11-02-2016, 02:46 PM   #1
andreclarenc
LQ Newbie
 
Registered: Nov 2016
Posts: 1

Rep: Reputation: Disabled
DD command


I use Linux Ubuntu. I would copy my DD on another DD. I use the command :"dd if=/dev/sda of=/dev/sdb": result : Permission non accordée (permission not allowed). Why ?

Thank you for your aid.

A. CLARENC
 
Old 11-02-2016, 02:48 PM   #2
szboardstretcher
Senior Member
 
Registered: Aug 2006
Location: Detroit, MI
Distribution: GNU/Linux systemd
Posts: 4,213

Rep: Reputation: 1614Reputation: 1614Reputation: 1614Reputation: 1614Reputation: 1614Reputation: 1614Reputation: 1614Reputation: 1614Reputation: 1614Reputation: 1614Reputation: 1614
Are you running as 'root'?

Are you positive this is what you want to do? 'dd' is known as the disk destroyer for those who don't use it properly.
 
1 members found this post helpful.
Old 11-02-2016, 03:05 PM   #3
snowpine
Senior Member
 
Registered: Feb 2009
Posts: 4,463

Rep: Reputation: 1296Reputation: 1296Reputation: 1296Reputation: 1296Reputation: 1296Reputation: 1296Reputation: 1296Reputation: 1296Reputation: 1296
Welcome to the forums!

There is no "root" in Ubuntu. Rather, Ubuntu uses a command called "sudo" as described here: https://help.ubuntu.com/community/RootSudo

So, you should append "sudo" to the start of your command if you want to run it with elevated (root) privileges.

Code:
sudo dd if=/dev/sda of=/dev/sdb
HOWEVER, please heed szboardstretcher's warning! "dd" is a very powerful command, to be used with caution.

Last edited by snowpine; 11-02-2016 at 03:14 PM.
 
Old 11-02-2016, 05:26 PM   #4
jpollard
Senior Member
 
Registered: Dec 2012
Location: Washington DC area
Distribution: Fedora, CentOS, Slackware
Posts: 4,749

Rep: Reputation: 1302Reputation: 1302Reputation: 1302Reputation: 1302Reputation: 1302Reputation: 1302Reputation: 1302Reputation: 1302Reputation: 1302Reputation: 1302
Quote:
Originally Posted by snowpine View Post
Welcome to the forums!

There is no "root" in Ubuntu. Rather, Ubuntu uses a command called "sudo" as described here: https://help.ubuntu.com/community/RootSudo

So, you should append "sudo" to the start of your command if you want to run it with elevated (root) privileges.

Code:
sudo dd if=/dev/sda of=/dev/sdb
HOWEVER, please heed szboardstretcher's warning! "dd" is a very powerful command, to be used with caution.
And don't do it while any of the filesystem(s) on /dev/sda are mounted read-write. You will only get a corrupted filesystem as a result.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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 On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] [SOLVED] bash script: can echo command, command works if I type, but command doesn't work in script ... why? hopeless_n00b Linux - Newbie 10 07-12-2018 06:57 AM
Does bash script has equivalent set /p command as Windows shell command? ncheng Linux - Newbie 5 06-30-2016 06:29 AM
Command/Script required to send an email alert in case command will not respond rajaniyer123 Linux - General 1 05-19-2012 02:12 PM
Executing shell command from JSP file with command line arg from URL orcusomega Programming 2 01-13-2012 04:38 PM
Bash Command Line Editor, while typing run another command before executing current? gumaheru Linux - General 5 04-13-2010 12:21 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - General > LinuxQuestions.org Member Success Stories

All times are GMT -5. The time now is 03:39 PM.

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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration