You cannot install real IDS on shared hosting, this is the responsibility of the host.
Hack-ish solution:
You can create a script that runs periodically (using cron or some other mechanism) that monitors all files and compares checksums with a previously saved record, and then notifies you of the differences.
To find out if your script itself was deleted by attack (1), you should also create a script session on the remote server (maybe something like the Google App Engine) that binds your shared server - the script, and checks if it receives the expected the result (perhaps a hash based on a given time) - if not, it sends you an email.
(1) This is actually unlikely, most attacks do not delete files
Joel l
source share