• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar
  • Skip to footer

TechLila

Bleeding Edge, Always

  • Home
  • About
  • Contact
  • Deals and Offers
Techlila Logo
Share
Tweet
Share
Pin
Great Programs to Capture Video on a PC
Up Next

7 Great Programs to Capture Video on a PC

Windows Command Prompt

TechLila Computer Windows

Use ‘Unix’ Commands on Windows – UnxUtils

Avatar of Rajesh Namase Rajesh Namase
Last updated on: January 23, 2022

Many people use both operating systems – Linux and Windows in their daily life. If you are one of those people who often keep switching between different operating systems in their work environment, you may have encountered scenarios when you have run Linux commands, such as ‘ls’ and ‘cd’ while working on the Windows command line. This can often happen with people who spend most of their time in server environments (typically ‘Unix’), and switch to the Windows environment (‘non Unix’), once in a while.

In such cases, the message ‘ls (or any Unix or Linux command that you entered on a Windows command prompt) is not recognized as an internal or external command, operable program or batch file.’ gets displayed at the command line as soon as you run a Linux command.

Windows Command Prompt

Now, here is an easy tip to work around this. There is a utility called ‘*UnxUtils*’ (Read as ‘Unix Utils’), which is a Windows compatible utility or library of commands used ‘Unix’ commands.

Note: Remember, the utility does not have all Windows-Linux compatibility commands, but only the most commonly used ones.

You can download binary file from one of the following links:

  • http://unxutils.sourceforge.net/
  • http://www.weihenstephan.de/~syring/win32/UnxUtils.zip

It contains GNU utilities for Win 32, which is dependent on the ‘msvcrt.dll’ file in the Windows Operating System.

Download the binary (‘.zip’) file and extract it on your computer. For example, ‘C:\UnxUtils’ indicates that the file is saved in the ‘C:’ drive.

Now, add the environment variable in the User variables:
Variable name: Path
Variable value: C:\unxutils\bin\;C:\unxutils\usr\local\wbin\

Environment Variables

If you don’t know how to change environment variable then read this tutorial. You can then open a new command prompt and type cd, ls, pwd, cat, or any of your favorite ‘Unix’ command. You can even run shell scripts.

Use Unix Commands on Windows

Note: If you already had a Command Line window opened then close it and open it again, as the PATH changes doesn’t apply to already running applications. If you want to use which command then add the windows extension .exe in its argument. For example, which which.exe.

Checkout this Wikipedia page for list of commands available through ‘UnxUtils’ in Windows. List is limited to commands included in C:\unxutils\usr\local\wbin\.

Additional Tools: Install Emacs and/or MinGW to get a more UNIX-like development environment on your Windows operating system.

Share
Tweet
Share
Pin

Disclosure: Content published on TechLila is reader-supported. We may receive a commission for purchases made through our affiliate links at no extra cost to you. Read our Disclaimer page to know more about our funding, editorial policies, and ways to support us.

Sharing is Caring

Share
Tweet
Share
Pin
Avatar of Rajesh Namase

Rajesh Namase

Rajesh Namase is a professional blogger and founder of TechLila blog. Also, he's a passionate entrepreneur, internet marketer, and fitness freak.

Category

  • Windows

Tags

UnxUtils

Reader Interactions

What people are saying

  1. Avatar of Harsh WarikooHarsh Warikoo

    hey nice effects on the page!
    especially the subtle way in which the snowfalls in the background! nice!
    keep it up!

    Reply
    • Avatar of Rajesh NamaseRajesh Namase

      I’m glad you liked it.

      Reply
  2. Avatar of mohanmohan

    Hello Rajesh, your Blog is very useful to me and everyone who want to become master on UNIX…
    Thank you..

    Reply
  3. Avatar of Priya BalakrishnanPriya Balakrishnan

    Hi first of all this is a great post, completely comprehensive! I am new to Unix and was looking for a way to practice it through Windows. I have a doubt. Please help me. How do I change directory in this. Since there is no cd command in the wbin, what is the other option for cd. Thanks in advance!

    Reply
    • Avatar of Rajesh NamaseRajesh Namase

      Yeah in wbin cd command is not their but you can use it. I’ve checked, ‘cd’ command working here.

      Reply
      • Avatar of Priya BalakrishnanPriya Balakrishnan

        Yes sir, I made a blunder by using cd.exe. Now I am clear. Thank You!

        Reply
  4. Avatar of Neerav ModiNeerav Modi

    Hi Rajesh,

    I have downloaded UnxUtils but somehow it does not seem to be working for me. I would really appreciate if you can help me sort out the problem. Below is what all I followed:

    Downloaded and extracted UnxUtils which is kept at below location:

    C:\UnxUtils
    Added user variable:
    Variable name: Path
    Variable value: C:\UnxUtils\bin\; C:\UnxUtils\usr\local\wbin\

    Now when I open the command prompt of windows and type ls then it gives me an error
    “‘ls’ is not recognized as an internal or external command, operable program or batch file.”

    Please help.

    Thanks,
    Neerav Modi

    Reply
    • Avatar of Rajesh NamaseRajesh Namase

      Have you added User Variables properly? I think you did some mistakes while adding user variables.

      Reply
  5. Avatar of VishiVishi

    This is super handy and helpful Rajesh!

    Reply

Add Your Comment Cancel reply

Your email address will not be published. Required fields are marked *

Primary Sidebar

Popular

How to Increase Broadband Speed on Windows

10 Best Android Launchers of 2021

Things to Do After Installing Windows 10 – Windows 10 Tips and Tricks

Top 10 Search Engines You Can Use to Search the Web Privately

55 Interesting Computer Facts That Will Blow Your Mind

What to Look for When Buying a Laptop – A Laptop Buying Guide

Fusion Drive Vs SSD – Things Nobody Tells you About Fusion vs SSD Storage

Useful Tools

• Grammarly – Free Grammar Checker
• SEMrush – The Best SEO Tool Trusted by Experts
• Setapp – One-stop subscription for Mac and iOS

Trending Topics

  • Android
  • Internet
  • iPhone
  • Linux
  • Macintosh
  • Security
  • Social Media
  • Technology
  • Windows

Worth Checking

10 Best Sound Equalizer for Windows 10 (2022 Edition!)

14 Best VLC Skins that are Highly Recommended and Free

Footer Logo Footer Text Logo

Footer

About

Hello and welcome to TechLila, the famous technology blog where you can find resourceful articles for mastering the basics and beyond.

At TechLila, our main goal is to provide unique information, such as quality tips and tricks, tutorials, how-to guides on Windows, Macintosh, Linux, Android, iPhone, Security and a few miscellaneous sub-topics such as reviews.

Links

  • About
  • Contact Us
  • Disclaimer
  • Privacy Policy
  • Terms

Follow

Custom Theme Using Genesis Framework

Cloud hosting by Cloudways

Language

en English
bg Българскиzh-CN 简体中文nl Nederlandsen Englishtl Filipinofr Françaisde Deutschid Bahasa Indonesiait Italianoja 日本語pl Polskipt Portuguêsro Românăru Русскийsr Српски језикes Españolsv Svenskatr Türkçeuk Українськаvi Tiếng Việt

© Copyright  2012–2023 TechLila. All Rights Reserved.