LinuxQuestions.org
Share your knowledge at the LQ Wiki.
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
 
LinkBack Search this Thread
Old 03-05-2013, 05:22 AM   #1
abhishekgoswami1
LQ Newbie
 
Registered: Jan 2009
Posts: 8

Rep: Reputation: 0
inotify_init Failed


I installed [inotify](https://github.com/rvoicilas/inotify-tools/wiki) and plugin code into my
existing code for watch file.I am always getting message that `inotify failed`.

I googled and found that kernel should with inotify option.(Not sure how will I check as I am using remote machine).

I have added all shared library in compilation.( does not relate but in case any possibility)

`Linux machinename 2.6.9-89.ELsmp #1 SMP Mon Apr 20 10:33:05 EDT 2009 x86_64 x86_64 x86_64 GNU/Linux`

Any idea How can I debug the issue as I am using inotify tool first time


inotify = inotify_init();
if(inotify<0)
{
loginfo<<" inotify_init fail"<<inotify<<endl;
}

output = -1
 
Old 03-05-2013, 06:36 AM   #2
chrism01
Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Centos 6.5, Centos 5.10
Posts: 16,093

Rep: Reputation: 1995Reputation: 1995Reputation: 1995Reputation: 1995Reputation: 1995Reputation: 1995Reputation: 1995Reputation: 1995Reputation: 1995Reputation: 1995Reputation: 1995
You should use the official repos to install inotify, instead of by hand.
eg
Code:
yum install inotify
 
  


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
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Bind9: NDC command failed : rndc: connect failed: connection refused Boudewijn Linux - Networking 19 01-02-2014 07:19 AM
[SOLVED] gparted error inotify_init failed: Too many open files masuch Linux - Newbie 4 01-19-2013 07:09 AM
Command failed: device-mapper: reload ioctl failed: Invalid argument azza Programming 2 01-10-2011 03:16 AM
online_update failed - ERROR(Media:connection failed)[Connect failed] rover Suse/Novell 8 02-22-2005 07:57 AM
unpacking of archive failed: cpio: read failed-input/output error rafc Linux - Newbie 0 04-21-2004 09:03 AM


All times are GMT -5. The time now is 05:16 AM.

Main Menu
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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration