LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
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, 08: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, 09: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, 09:26 AM   #3
Satyaveer Arya
Senior Member
 
Registered: May 2010
Location: Palm Island
Distribution: RHEL, CentOS, Debian, Oracle Solaris 10
Posts: 1,415

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, 09: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, 09:50 AM   #5
Satyaveer Arya
Senior Member
 
Registered: May 2010
Location: Palm Island
Distribution: RHEL, CentOS, Debian, Oracle Solaris 10
Posts: 1,415

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


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 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 12:45 PM
program running time comparison under Linux Desktop, Linux Server and Windows Xp crs_zxf Linux - Newbie 2 05-07-2009 11:27 AM
compiling and running a c program in Linux myrto Linux - Newbie 6 12-21-2006 06:11 PM
Having Problem with Running a Program in RH linux 8.0 cheenaik Linux - Software 18 06-03-2006 08:41 AM
running linux ccommands in a C program DJOtaku Programming 4 10-03-2005 06:13 AM


All times are GMT -5. The time now is 09:49 AM.

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