I believe man signal will give you more info, but here's what I use:
ps aux | grep programname
ps aux | grep ftp
Would give me info about where proftpd is running, then I'd note the pid and:
kill -15 1234
Where 1234 is the pid.
A 15 signal tells the application to finish up and close. It's clean. If your application doesn't respond to that, you can kill -9 it instead.
A 9 signal tells it to stop right now and close, actually I think it might even happen further up the chain of events, such as get killed from it's source rather than the application itself. It's much worse for the application, and should only be used when 15 (or others) aren't working.
I hope I've got those correct, see man signal for more info