What is /dev/null in Unix?

Asked by Last Modified  

6 Answers

Learn Linux

Follow 6
Answer

Please enter your answer

Linux Administration Certification and UNIX Shell Scripting

It is a bit bucket in Unix where you dump things you don't need. When you need to discard output from your command , you can redirect it to /dev/null. In Unix, an external device is treated as a file. All such devices are found as files in /dev directory. It is a Null device . Suppose you need to...
read more
It is a bit bucket in Unix where you dump things you don't need. When you need to discard output from your command , you can redirect it to /dev/null. In Unix, an external device is treated as a file. All such devices are found as files in /dev directory. It is a Null device . Suppose you need to search for a pattern, but do not need it to be displayed to the console, but need the exit code of the command, we can do grep pattern filename > /dev/null # search without displaying it to console. echo $? # exit code You can also redirect your standard error messages from a command to /dev/null as $cmd 2> /dev/null Here 2> represents standard error. /dev/null is the bit-bucket: the place where you dump anything you don't need. /dev/null is a special file-system object that throws away everything written into it. Redirecting a stream into it means hiding an output. read less
Comments

Programming Language Trainer - Java, Python, .NET, Power BI, Tableau, Excel, SQL, Data Analytics

it is used to dispose off unwanted files or devices in Unix. it is a special file, not a directory, therefore, one cannot use mv command to move files in /dev/null.
Comments

Training Professional

/dev/null is the null file Is is a special file which contains nothing.
Comments

Linux Admin Trainer

/dev/null is a file. if we want to nullify something we can redirect the output to this file. Ex: find / -name linux >> /dev/null
Comments

Trainer

Its a file which stands for the null file or if i comoare it with windows OS,we can call it as a permanently deleting the file by pressing Shift+del key .
Comments

IT Professional Trainer with 13 Years of Experience

its an black hole you can send any junk data.
Comments

View 4 more Answers

Related Questions

I am working as Tech support executive with windows and Linux total of 4 years of experience , Not getting enough calls / opportunities ... Which domain is good for change Sap basis consultant / any other suggestions are welcome

Learn Cloud Computing(Microsoft Azure,AWS,Google Cloud) or Devops. Make your career in this field. Your previous experience will use in this field.
Vamshi
My name is Rajesh , working as a Recruiter from past 6 years and thought to change my career into software (development / admin/ testing ) am seeking for some suggestion which technology I need to learn ? Any job after training ? Or where I can get job within 3 months after finishing my training programme- your advices are highly appreciated
Mr rajesh if you want to enter in to software Choose SAP BW AND SAP HANA because BW and HANA rules the all other erp tools next 50 years.it provides rubust reporting tools for quicker decesion of business It very easy to learn
Rajesh
1 0
6
What is openstack ?
OpenStack is open source platform for building and managing cloud computing platforms for public and private clouds in a cloud computing environment.
Vivek
What is the cost of linux course and how much do the certification cost?
1000 for basic and 2000 for linux advance, for certification, give exam, clear it and you are certified
Anusha

Now ask question in any of the 1000+ Categories, and get Answers from Tutors and Trainers on UrbanPro.com

Ask a Question

Related Lessons

How to detect duplicate address manually in a network from Linux ?
Below script will help you to detect duplicate IP address in a subnet The key command is the arping command which will send out an ARP packet with DAD (duplicate address detection) If the return...

How To Start Shell Scripting?
Hi learners, I would like to share my knowledge in shell scripting: Every new Linux learners goal is to learn shell scripting. But only a few starts quickly writing the shell scripts.Why? The reasons...

Linux Introdution
Linux is a UNIX-base operating system. Its original creator was a Finnish student name Linus Torvalds, although being ‘open source’ it has change a great deal since its original conception....

LINUX SERVER ADMINISTRATION
Permissions in Linux rwx|rwx|rwx =user | group | others R==4 W==2 X==1 what's the total? 421|421|421 777 So 7 has 4, 2,1==which means full. Permission (that is read write and execute) ...

Linux Syllabus
Part I Geting Familiar with Red Hat Enterprise Linux Chapter 1 Geting Started with Red Hat Enterprise Linux Linux, Open Source, and Red Hat Origins of Linux Distributions Fedora Red Hat Enterprise...

Recommended Articles

Software Development has been one of the most popular career trends since years. The reason behind this is the fact that software are being used almost everywhere today.  In all of our lives, from the morning’s alarm clock to the coffee maker, car, mobile phone, computer, ATM and in almost everything we use in our daily...

Read full article >

Almost all of us, inside the pocket, bag or on the table have a mobile phone, out of which 90% of us have a smartphone. The technology is advancing rapidly. When it comes to mobile phones, people today want much more than just making phone calls and playing games on the go. People now want instant access to all their business...

Read full article >

Information technology consultancy or Information technology consulting is a specialized field in which one can set their focus on providing advisory services to business firms on finding ways to use innovations in information technology to further their business and meet the objectives of the business. Not only does...

Read full article >

Hadoop is a framework which has been developed for organizing and analysing big chunks of data for a business. Suppose you have a file larger than your system’s storage capacity and you can’t store it. Hadoop helps in storing bigger files than what could be stored on one particular server. You can therefore store very,...

Read full article >

Looking for Linux Training?

Learn from the Best Tutors on UrbanPro

Are you a Tutor or Training Institute?

Join UrbanPro Today to find students near you