LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 01-22-2012, 07:42 AM   #1
naushi
LQ Newbie
 
Registered: Jan 2012
Posts: 10

Rep: Reputation: Disabled
Question help with running a Linux program


i have a redhat Linx - i am trying to run a prog that I created but it wont run. it keeps saying prog not found. i am in the right directory - it shows the prog name when I do an ls -l but it wont run. I also tried ./myprog1 but does not find the directory. I also dont know how to see the version of Linux

your help will be greatly appreciated.
 
Old 01-22-2012, 08:18 AM   #2
willettwork
LQ Newbie
 
Registered: Dec 2011
Distribution: Ubuntu 11.01 64bit
Posts: 5

Rep: Reputation: Disabled
Hiya

I'm impressed that you wrote a program. I'm tying to bend my brain around Java.

As to your question. Te only thing I can think of that would interfere Linuz-wize is permissions. You need to have execute permits on the file and the folder it is in.
 
Old 01-22-2012, 08:26 AM   #3
Satyaveer Arya
Senior Member
 
Registered: May 2010
Location: Palm Island
Distribution: RHEL, CentOS, Debian, Oracle Solaris 10
Posts: 1,420

Rep: Reputation: 305Reputation: 305Reputation: 305Reputation: 305
Welcome to LQ.

Quote:
i am trying to run a prog that I created but it wont run.
You haven't mentioned which program on which software language you wrote?

Quote:
I also tried ./myprog1 but does not find the directory.
Have you given the executable permission to the program file?

And use uname -a command to see the version and all.
 
Old 01-22-2012, 08:36 AM   #4
naushi
LQ Newbie
 
Registered: Jan 2012
Posts: 10

Original Poster
Rep: Reputation: Disabled
got it

permission was the issue. it only works with ./ - however when I create a new file it assigns and S to the owner executable . like rwxrwSrwx. but I can do anything with the file though.

thanks a lot
 
Old 01-22-2012, 08:50 AM   #5
Satyaveer Arya
Senior Member
 
Registered: May 2010
Location: Palm Island
Distribution: RHEL, CentOS, Debian, Oracle Solaris 10
Posts: 1,420

Rep: Reputation: 305Reputation: 305Reputation: 305Reputation: 305
Now if your problem has been solved, you can mark it as SOLVED.
 
  


Reply



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



Similar Threads
Thread Thread Starter Forum Replies Last Post
running c graphics program in linux shrey8919 Programming 1 09-20-2010 11:45 AM
program running time comparison under Linux Desktop, Linux Server and Windows Xp crs_zxf Linux - Newbie 2 05-07-2009 10:27 AM
compiling and running a c program in Linux myrto Linux - Newbie 6 12-21-2006 05:11 PM
Having Problem with Running a Program in RH linux 8.0 cheenaik Linux - Software 18 06-03-2006 07:41 AM
running linux ccommands in a C program DJOtaku Programming 4 10-03-2005 05:13 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 02: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
Open Source Consulting | Domain Registration