Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8417065
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 10, 20262026-06-10T01:56:25+00:00 2026-06-10T01:56:25+00:00

As I am new to bash scripting (vbs is more my stuff), I can’t

  • 0

As I am new to bash scripting (vbs is more my stuff), I can’t get this to run. Probably very simple for y’all:

I have a bash script on the C-system disk that is starting a NagWin (nagios for windows) plugin, but in that script I want to start off with a line of code that does a file existence checking on the D-drive in a certain folder.

If this file is there, it just can echo a message and exit,
else if this is not there it should continue with the script on the C-drive

The other part of the script runs well only it does not do any checking, probably because something is wrong with the jumping to d drive and c drive or something

Already thanks

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-10T01:56:26+00:00Added an answer on June 10, 2026 at 1:56 am
    if [ -f D:/file/on/d/drive ]
    then C:/script/on/c/drive
    else echo "Did not find file D:/file/on/d/drive" 1>&2
    fi
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am fairly new to bash scripting. I can't seem to get the correct
I'm very new to bash scripting and I'm trying to practice by making this
I'm quiet new to bash scripting, and I would like to convert recursively all
I'm quite new to bash scripting and usually avoid it all costs but I
I am very new to Bash scripting. I am trying to write a script
I'm very new to bash scripting and am running into an issue when using
I am new to bash-scripting & trying to understand how things work. It's all
I am not exactly a pro at BASH Scripting, but I can get by
Hello im new to bash scripting, i have a simple program which is not
I am very new to bash scripting. I have the following script: cp /etc/apt/sources.list

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.