-3

Ok, so I have this Virtual Dedicated Server laying around, and I thought I'd turn it into a game server. So, I used wget in PuTTy to download the Half-Life Game server installer package, but when I go to run it, it says "No such file or directory exists". But, when I list the files in the directory, it shows up, so it's there, but it's not recognizing it for some reason. What's causing this?

Josh
  • 13
  • 1
  • You need to give us a lot more information so that we can help you. What Operating System are you running? Have you checked the error logs in /var/log? What do you do when you try to "run the installer package" (what commands are you running, what type of file is it, etc...)? Also, not trying to be a jerk, but this question could very well be considered off topic, per the FAQ (http://serverfault.com/faq). – David W Jul 07 '12 at 16:57

2 Answers2

2

You'll see this happen when the binary is a different architecture than the system you're running.

Execute these commands:

uname -m

(Probably reports x86_64)

and

file <half-life-game-server>

(Probably reports ELF 32-bit LSB executable)

Is it the same architecture?

In order to run 32-bit binaries on a 64-bit system you need the 32-bit glibc runtime. For Debian/Ubuntu install the libc6-i386 package.

bahamat
  • 6,263
  • 24
  • 28
1

I am 99% certain that your problem is that you didn't download the file to a location in $PATH. Unlike on Windows, most Unixes don't consider the current directory to be in the path by default.

You need to move the file to a directory in $PATH (for instance, /usr/local/bin is probably in it) or give the path to the executable when you run it, for instance ./install.sh.

The remaining 1% is forgetting to use chmod to mark the file executable after downloading it.

DerfK
  • 19,493
  • 2
  • 38
  • 54