Mediaserver indexing: correct updating (WiKi) SOLVED

Questions about using 3rd party Media Streaming software may go here
Forum rules
Please note the disclaimer before modifying your Synology Product.

Mediaserver indexing: correct updating (WiKi) SOLVED

Postby manslife » Wed Nov 10, 2010 12:57 pm

NO MORE FULL reindex and etc !!!

Add daemon for indexing, which do need action to database
and multimedia indexing in full automat indexing.

Q: Why is script need ?
A: This Auto update realy update indexes on any actions with files: (on current inotify synoinex can`t do indexis in example variants)
For example if you copy to multimedia dir`s from WinSCP, Telnet, SSH, from mc or from sh scripts like cp * mv* and etc.

HOW:

Step #1:
Add this sh to full verife db index`s on start syno
Create file with text in path: /usr/local/etc/rc.d/S92_mediaindex.sh with chrown do "exec" right`s
Code: Select all
#!/bin/sh
#
# update all indexes in db on syno
# NO MORE FULL reindex and etc
# by manslife 2010-11-13

case "$1" in
  start|"")

#
# input dirs
mkdir -p /tmp/mediaindex
music="/volume1/music"
video="/volume1/video"
photo="/volume1/photo"

# Setup find correctly.
export IFS=$'\n'

#sleep 10
echo `date` "Autoindex start indexing: " >> /var/log/messages
# Loop through our array.
for x in $music $video $photo
   do

if [ "$x" == "/volume1/music" ]; then
nn="music"
fi
if [ "$x" == "/volume1/video" ]; then
nn="video"
fi
if [ "$x" == "/volume1/photo" ]; then
nn="photo"
fi

# Find all directories & subdirectories
/opt/bin/find $x -type d -wholename '*' ! -wholename */@eaDir* > /tmp/mediaindex/$nn.dir
/opt/bin/sort /tmp/mediaindex/$nn.dir -o /tmp/mediaindex/$nn.dir

/usr/syno/pgsql/bin/psql mediaserver admin -tA -c "select path from directory where path like '$x%'" > /tmp/mediaindex/$nn-pgsql.dir
/opt/bin/sort /tmp/mediaindex/$nn-pgsql.dir -o /tmp/mediaindex/$nn-pgsql.dir

# Find all Files and exclude win files
/opt/bin/find $x -type f -wholename '*' ! -wholename */@eaDir* ! -name '*.ini' ! -name '*.db' ! -name '*.sys' ! -name '*.zip' ! -name '*.ra?' > /tmp/mediaindex/$nn.file
/opt/bin/sort /tmp/mediaindex/$nn.file -o /tmp/mediaindex/$nn.file

/usr/syno/pgsql/bin/psql mediaserver admin -tA -c "select path from $nn where path like '$x%'" > /tmp/mediaindex/$nn-pgsql.file
/opt/bin/sort /tmp/mediaindex/$nn-pgsql.file -o /tmp/mediaindex/$nn-pgsql.file

# Looking + -
/opt/bin/diff /tmp/mediaindex/$nn.dir /tmp/mediaindex/$nn-pgsql.dir |grep "<"|cut -c3-9000 > /tmp/mediaindex/$nn-dif-ON.dir
/opt/bin/diff /tmp/mediaindex/$nn.file /tmp/mediaindex/$nn-pgsql.file |grep "<"|cut -c3-9000 > /tmp/mediaindex/$nn-dif-ON.file

/opt/bin/diff /tmp/mediaindex/$nn.dir /tmp/mediaindex/$nn-pgsql.dir |grep ">"|cut -c3-9000 > /tmp/mediaindex/$nn-dif-OFF.dir
/opt/bin/diff /tmp/mediaindex/$nn.file /tmp/mediaindex/$nn-pgsql.file |grep ">"|cut -c3-9000 > /tmp/mediaindex/$nn-dif-OFF.file
#######################################
# REMOVE all needed directories & subdirectories
for i in $( /opt/bin/cat /tmp/mediaindex/$nn-dif-OFF.dir )
do
/usr/syno/bin/synoindex -D "$i" > /dev/null
echo `date` "Autoindex REMOVE DIRs: " $i >> /var/log/messages
done

# REMOVE all needed files
for i in $( /opt/bin/cat /tmp/mediaindex/$nn-dif-OFF.file)
do
/usr/syno/bin/synoindex -d "$i" > /dev/null
echo `date` "Autoindex REMOVE FILES: " $i >> /var/log/messages
done

# ADD all needed directories & subdirectories
for i in $( /opt/bin/cat /tmp/mediaindex/$nn-dif-ON.dir )
do
/usr/syno/bin/synoindex -A "$i" > /dev/null
echo `date` "Autoindex ADD DIRs: " $i >> /var/log/messages
done

# ADD all needed files
for i in $( /opt/bin/cat /tmp/mediaindex/$nn-dif-ON.file)
do
/usr/syno/bin/synoindex -a "$i" > /dev/null
echo `date` "Autoindex ADD FILES: " $i >> /var/log/messages
done

done
rm -fr /tmp/mediaindex
echo `date` "Autoindex END indexing: " >> /var/log/messages

   ;;
  restart|reload|force-reload)
   echo "Error: argument '$1' not supported" >&2
   exit 3
   ;;
  stop)
   #
   ;;
  *)
   echo "Usage: inotifywait.sh [start|stop]" >&2
   exit 3
   ;;
esac

:



Step #2 : For full automatic daemon need to install "inotify-tools"


Download http://github.com/downloads/rvoicilas/inotify-tools/inotify-tools-3.14.tar.gz
unpak file, copy dir to syno and exeс in console:
path to unpacked dir/configure --prefix=/usr && make && su -c 'make install'

Site for FAQ https://github.com/rvoicilas/inotify-tools/wiki#getting

whait on same actions ...... and all done.


Now Create file with text in path: /usr/local/etc/rc.d/S93_mediaindexdm.sh

Code: Select all
#!/bin/sh
# Looking FULL changes

case "$1" in
  start|"")

#NEW Variant: dirs ends white slashes
/usr/bin/inotifywait -mrcq -e close_write -e moved_to -e moved_from -e move -e create -e delete -e unmount /volume1/music /volume1/photo /volume1/video | while read -r; do
eval "$(echo "$REPLY" | sed -r 's#'\''#'\'\\\\\'\''#; s#^("([^"]*)"|([^"][^,]*)),("([^"]*)"|([^"][^,]*)),("([^"]*)"|([^"][^,]*))$#file_name='\''\2\3\8\9'\''; action='\''\5\6'\''#')"

#if [ "$action" = "CREATE" ] ; then
#echo '0 NOTHING to file CREATE! ONLY on WRITE_CLOSE'
#fi

if [ "$action" = "CREATE,ISDIR" ] ; then
/usr/syno/bin/synoindex -A "$file_name" > /dev/null
echo "At `date`, Autoindex ADD DIRs: "  "$file_name" >> /var/log/messages
fi
if [ "$action" = "CLOSE_WRITE,CLOSE" ] ; then
/usr/syno/bin/synoindex -a "$file_name" > /dev/null
echo "At `date`, Autoindex ADD FILES: " "$file_name" >> /var/log/messages
fi
if [ "$action" = "DELETE" ] ; then
/usr/syno/bin/synoindex -d "$file_name" > /dev/null
echo "At `date`, Autoindex REMOVE FILES: " "$file_name" >> /var/log/messages
fi
if [ "$action" = "DELETE,ISDIR" ] ; then
/usr/syno/bin/synoindex -D "$file_name" > /dev/null
echo "At `date`, Autoindex REMOVE DIRs: " "$file_name" >> /var/log/messages
fi
if [ "$action" = "MOVED_FROM,ISDIR" ] ; then
/usr/syno/bin/synoindex -D "$file_name" > /dev/null
echo "At `date`, Autoindex REMOVE DIRs: " "$file_name" >> /var/log/messages
fi
if [ "$action" = "MOVED_FROM" ] ; then
/usr/syno/bin/synoindex -d "$file_name" > /dev/null
echo "At `date`, Autoindex REMOVE FILES: " "$file_name" >> /var/log/messages
fi
if [ "$action" = "MOVED_TO,ISDIR" ] ; then
/usr/syno/bin/synoindex -A "$file_name" > /dev/null
echo "At `date`, Autoindex ADD DIRs: " "$file_name" >> /var/log/messages
fi
if [ "$action" = "MOVED_TO" ] ; then
/usr/syno/bin/synoindex -a "$file_name" > /dev/null
echo "At `date`, Autoindex ADD FILES: " "$file_name" >> /var/log/messages
fi
done &

   ;;
  restart|reload|force-reload)
   echo "Error: argument '$1' not supported" >&2
   exit 3
   ;;
  stop)
   killall inotifywait
   ;;
  *)
   echo "Usage: inotifywait.sh [start|stop]" >&2
   exit 3
   ;;
esac

:



All done.

With this daemons HDD DISK`s on Syno go to hibernate without problem.

DS210j FW Version: DSM 3.0-1354
Last edited by manslife on Wed Nov 17, 2010 7:24 am, edited 6 times in total.
manslife
Trainee
Trainee
 
Posts: 14
Joined: Sun Mar 14, 2010 3:09 pm

Re: Mediaserver indexing: correct updating (WiKi) SOLVED

Postby manslife » Mon Nov 15, 2010 7:19 pm

Update to daemon.

All test done. Update all files on th fly.
manslife
Trainee
Trainee
 
Posts: 14
Joined: Sun Mar 14, 2010 3:09 pm

Re: Mediaserver indexing: correct updating (WiKi) SOLVED

Postby manslife » Mon Nov 15, 2010 7:58 pm

On my system installed many packages:

Ds210j> ipkg list_installed
adduser - 1.10.3-1 - a multi-call binary for login and user account administration
apr - 1.3.12-1 - Apache Portable Runtime library
apr-util - 1.3.9-1 - Apache Portable Runtime utilities library
aria2 - 1.10.6-1 - A utility for downloading files. The supported protocols are HTTP(S), FTP, BitTorrent (DHT, PEX, MSE/PE), and Metalink.
autoconf - 2.67-1 - Creating scripts to configure source code packages using templates
automake - 1.10-2 - Creates GNU standards-compliant Makefiles from template files
bash - 3.2.49-1 - A bourne style shell
binutils - 2.19.1-1 - The GNU assembler and linker and related tools
bison - 2.4.1-1 - a general-purpose parser generator that converts an annotated context-free grammar into an LALR(1) or GLR parser for that gramm
bzip2 - 1.0.6-1 - Very high-quality data compression program
c-ares - 1.7.3-1 - C library that performs DNS requests and name resolves asynchronously
ccrypt - 1.9-1 - Secure encryption and decryption of files and streams
coreutils - 8.4-1 - Bunch of heavyweight *nix core utilities
cpio - 2.9-3 - file archive utility
cyrus-sasl-libs - 2.1.23-1 - Provides client or server side authentication (see RFC 2222).
davtools - 1.2.0-1 - Disk Allocation Viewer - obtain the state of fragmentation on disk.
diffutils - 3.0-1 - contains gnu diff, cmp, sdiff and diff3 to display differences between and among text files
dstat - 0.7.0-1 - dstat is a versatile replacement for vmstat, iostat, netstat, nfsstat, and ifstat
e2fslibs - 1.41.9-1 - Ext2 Filesystem Libraries
e2fsprogs - 1.41.9-1 - Ext2 Filesystem Utilities
expat - 2.0.1-1 - XML Parser library
fdupes - 1.40-1 - FDUPES is a program for identifying or deleting duplicate files residing within specified directories.
file - 5.04-1 - Ubiquitous file identification utility.
findutils - 4.2.32-1 - File finding utilities
flex - 2.5.35-1 - Generates programs that perform pattern-matching on text.
gawk - 3.1.8-1 - Gnu AWK interpreter
gcc - 4.2.3-1 - The GNU Compiler Collection.
gconv-modules - 2.5-1 - Provides gconv modules missing from the firmware. These are used by glibc iconv() implementation.
gdbm - 1.8.3-2 - GNU dbm is a set of database routines that use extensible hashing. It works similar to the standard UNIX dbm routines.
getopt - 2.15-2 - The getopt utility from the util-linux-ng package.
gettext - 0.14.5-2 - Set of tools for producing multi-lingual messages
glib - 2.20.4-1 - The GLib library of C routines.
grep - 2.7-1 - Global regular expression parser
groff - 1.19.2-2 - front-end for the groff document formatting system
gzip - 1.2.4a-4 - GNU Zip data compression program
libc-dev - 2.5-5 - libc development files.
libcurl - 7.21.2-1 - Curl is a command line tool for transferring files with URL syntax, supporting FTP, FTPS, HTTP, HTTPS, GOPHER, TELNET, DICT, FI
libdb - 4.2.52-3 - Berkeley DB Libraries
libgmp - 4.3.2-1 - GNU Multiple Precision Arithmetic Library.
libidn - 1.19-1 - GNU Libidn is an implementation of the Stringprep, Punycode and IDNA specifications defined by the IETF Internationalized Domai
libjpeg - 6b-3 - collection of jpeg tools
libnsl - 2.5-4 - Network Services Library
libpng - 1.2.44-1 - Portable Network Graphics Libraries
libstdc++ - 6.0.9-6 - Standard C++ library, needed for dynamically linked C++ programs
libtool - 1.5.26-1 - Library tools.
libusb - 0.1.12-2 - Library for interfacing to the USB subsystem.
libxml2 - 2.7.7-2 - Libxml2 is the XML C parser and toolkit developed for the Gnome project.
lsof - 4.82-1 - LiSt Open Files - a diagnostic tool.
m4 - 1.4.15-1 - gnu macro processor and compiler front end
make - 3.82-1 - examines files and runs commands necessary for compilation
mc - 4.7.4-1 -
nbench-byte - 2.2.2-1 - BYTE's Native Mode Benchmarks
ncurses - 5.7-1 - NCurses libraries
ncursesw - 5.7-1 - NCurses libraries with wide char support
neon - 0.29.3-1 - an HTTP and WebDAV client library, with a C interface
openldap-libs - 2.3.43-2 - Open Lightweight Directory Access Protocol
openssh - 5.5p1-1 - a FREE version of the SSH protocol suite of network connectivity tools.
openssl - 0.9.8o-1 - Openssl provides the ssl implementation in libraries libcrypto and libssl, and is needed by many other applications and librari
optware-devel - 6.8-10 - This is a meta package that bundles all the packages required for optware native development. When fully functional, it should
patch - 2.6.1-1 - applies a diff to produce a patched file
pcre - 8.10-1 - Perl-compatible regular expression library
perl - 5.10.0-6 - Practical Extraction and Report Language.
pkgconfig - 0.15.0-2 - Package configuration tool
procps - 3.2.8-1 - PROCPS System Utilities
psmisc - 22.13-1 - A set of some small useful utilities that use the proc filesystem.
python - 2.5-1 - This is a package that sets up the default python.
python25 - 2.5.5-2 - Python is an interpreted, interactive, object-oriented programming language.
python26 - 2.6.6-1 - Python is an interpreted, interactive, object-oriented programming language.
readline - 6.1-2 - The GNU Readline library provides a set of functions for use by applications that allow users to edit command lines as they are
rsync - 3.0.7-1 - fast remote file copy program (like rcp)
sdparm - 1.05-1 - Utility for listing and potentially changing SCSI disk parameters
sed - 4.2.1-1 - Stream editor.
slang - 2.2.2-1 - S-Lang is a multi-platform library designed to allow a developer to create robust multi-platform software.
smartmontools - 5.40-3 - Utility programs to control and monitor (SMART) built into most modern ATA and SCSI hard disks.
sqlite - 3.7.3-1 - SQLite is a small C library that implements a self-contained, embeddable, zero-configuration SQL database engine.
svn - 1.6.13-1 - a compelling replacement for CVS
tar - 1.25-1 - heavyweight version of the Tape ARchiver
tcl - 8.4.19-2 - The Tool Command Language
termcap - 1.3.1-2 - Terminal emulation library
unrar - 3.9.8-1 - unrar is an application that can decompress files and archives created using the RAR compression scheme
unzip - 6.0-2 - A (de)compression library for the ZIP format
usbutils - 0.73-3 - USB enumeration utilities
util-linux-ng - 2.15-2 - A suite of essential utilities for any Linux system, this version is a fork of util-linux.
wget-ssl - 1.12-2 - A network utility to retrieve files from the Web
zip - 3.0-1 - a compression and file packaging utility.
zlib - 1.2.5-1 - zlib is a library implementing the 'deflate' compression system.
Successfully terminated.
manslife
Trainee
Trainee
 
Posts: 14
Joined: Sun Mar 14, 2010 3:09 pm

Re: Mediaserver indexing: correct updating (WiKi) SOLVED

Postby manslife » Wed Nov 17, 2010 7:32 am

Update issue when dir`s ends whith spaces example
"\volume1\music\dirname "


How was: full path
"\volume1\music\dirname\file.*"

It`s incorrect full path and index not update correctly.

How now: indexes update`s to full path
"\volume1\music\dirname \file.*"

Now Full path are correct.
manslife
Trainee
Trainee
 
Posts: 14
Joined: Sun Mar 14, 2010 3:09 pm

Re: Mediaserver indexing: correct updating (WiKi) SOLVED

Postby Grimmoire » Fri Nov 19, 2010 8:14 pm

Hi,

I've some problem to install "inotify-tools" :
./configure --prefix=/usr =>
Code: Select all
[...]
configure: creating ./config.status
config.status: creating Makefile
gawk: ./conf6502-6944/subs.awk:2: S["/; s/!.*/"]=am__EXEEXT_FALSE!%!_!# ""
gawk: ./conf6502-6944/subs.awk:2:                                 ^ syntax error
gawk: ./conf6502-6944/subs.awk:3: S["/; s/!.*/"]=am__EXEEXT_FALSE!%!_!# ""
gawk: ./conf6502-6944/subs.awk:3:                                     ^ syntax error
[...]

I've a DS710+.

Any idea ?
Last edited by Grimmoire on Mon Nov 22, 2010 8:16 am, edited 1 time in total.
Grimmoire
I'm New!
I'm New!
 
Posts: 3
Joined: Thu Nov 11, 2010 12:48 pm

Re: Mediaserver indexing: correct updating (WiKi) SOLVED

Postby bomber456 » Sun Nov 21, 2010 7:15 pm

anyone care to explain this more clearly? not sure what to do!
bomber456
I'm New!
I'm New!
 
Posts: 3
Joined: Mon Nov 01, 2010 12:46 pm

Re: Mediaserver indexing: correct updating (WiKi) SOLVED

Postby manslife » Mon Nov 22, 2010 7:29 pm

My steeps to install all needed packages before inotify tools and sh scripting ...

Code: Select all
mkdir -p /volume1/tmp/bootstrap
cd /volume1/tmp/bootstrap
wget http://ipkg.nslu2-linux.org/feeds/optware/cs08q1armel/cross/unstable/syno-mvkw-bootstrap_1.2-7_arm.xsh
sh syno-mvkw-bootstrap_1.2-7_arm.xsh
rm syno-mvkw-bootstrap_1.2-7_arm.xsh
ipkg update
ipkg upgrade
ipkg remove wget
ipkg install wget-ssl
ipkg install pcre glib e2fsprogs slang libpng
ipkg install gcc binutils optware-devel gettext gconv-modules
ipkg install bash
ipkg install file zip gawk termcap


Next, i install admins packages

Code: Select all
/opt/bin/ipkg install bash
/opt/bin/ipkg install binutils || /opt/bin/ipkg install crosstool-native
/opt/bin/ipkg install bzip2
/opt/bin/ipkg install davtools
/opt/bin/ipkg install ccrypt
/opt/bin/ipkg install coreutils
/opt/bin/ipkg install diffutils
/opt/bin/ipkg install dstat
/opt/bin/ipkg install fdupes
/opt/bin/ipkg install file
/opt/bin/ipkg install findutils
/opt/bin/ipkg install gcc
/opt/bin/ipkg install grep
/opt/bin/ipkg install gzip
/opt/bin/ipkg install make
/opt/bin/ipkg install nbench-byte
/opt/bin/ipkg install procps
/opt/bin/ipkg install psmisc
/opt/bin/ipkg install rsync
# /opt/bin/ipkg install samba   # alternative look last section
/opt/bin/ipkg install sdparm
/opt/bin/ipkg install sed
/opt/bin/ipkg install tar
/opt/bin/ipkg install unrar
/opt/bin/ipkg install unzip
/opt/bin/ipkg install zip
/opt/bin/ipkg install e2fsprogs
/opt/bin/ipkg install lsof
/opt/bin/ipkg install usbutils
/opt/bin/ipkg install smartmontools
/opt/bin/ipkg install util-linux-ng
#
# alternative to install tdbtool
#
/opt/bin/ipkg download samba
/bin/tar -xvzf samba* ./data.tar.gz
/bin/tar -xvzf data.tar.gz ./opt/bin/tdbtool
/bin/mv ./opt/bin/tdbtool /opt/bin/tdbtool
/bin/rm -rf ./opt
/bin/rm -f ./samba*
manslife
Trainee
Trainee
 
Posts: 14
Joined: Sun Mar 14, 2010 3:09 pm

Re: Mediaserver indexing: correct updating (WiKi) SOLVED

Postby manslife » Mon Nov 22, 2010 7:36 pm

Grimmoire wrote:Hi,

I've some problem to install "inotify-tools" :
./configure --prefix=/usr =>
Code: Select all
[...]
configure: creating ./config.status
config.status: creating Makefile
gawk: ./conf6502-6944/subs.awk:2: S["/; s/!.*/"]=am__EXEEXT_FALSE!%!_!# ""
gawk: ./conf6502-6944/subs.awk:2:                                 ^ syntax error

Any idea ?


Before install, Try to install packages:
gcc, gawk, make, coreutils, findutils and diffutils
manslife
Trainee
Trainee
 
Posts: 14
Joined: Sun Mar 14, 2010 3:09 pm

Re: Mediaserver indexing: correct updating (WiKi) SOLVED

Postby Grimmoire » Mon Nov 22, 2010 11:34 pm

Thx manslife !

With admins package installed, all's fine !

I notice just :
Code: Select all
./S93_mediaindexdm.sh: read: 61: arg count

Thanks to sharing your work manslife :)
Grimmoire
I'm New!
I'm New!
 
Posts: 3
Joined: Thu Nov 11, 2010 12:48 pm

Re: Mediaserver indexing: correct updating (WiKi) SOLVED

Postby manslife » Thu Nov 25, 2010 4:40 pm

On my system all code run fine

try change "exit 3" to "exit"

Code: Select all
 echo "At `date`, Autoindex ADD FILES: " "$file_name" >> /var/log/messages
fi
done &

   ;;
  stop)
   killall inotifywait
   ;;
  *)
   echo "Usage: inotifywait.sh [start|stop]" >&2
   exit
   ;;
esac

:
manslife
Trainee
Trainee
 
Posts: 14
Joined: Sun Mar 14, 2010 3:09 pm

Re: Mediaserver indexing: correct updating (WiKi) SOLVED

Postby chtitbidule » Thu Dec 09, 2010 3:20 pm

Hi all,

Thank you manlife for your script ! It is exactly what I expected !
(Excuse me for my bad english, I'm french ... )

Could you explain to me why I'm getting many many lines (like above) in /var/log/messages ? These lines appear when I copy a file from a server to DS210j through NFS ... I modified S93_mediaindexdm.sh script in order to see CLOSE_WRITE or MOVED_TO ...

Thu Dec 9 15:15:42 CET 2010, Autoindex ADD FILES \(CLOSE_WRITE\): /volume1/video/Fafa.AVI
At Thu Dec 9 15:15:42 CET 2010, Autoindex ADD FILES \(CLOSE_WRITE\): /volume1/video/Fafa.AVI
At Thu Dec 9 15:15:42 CET 2010, Autoindex ADD FILES \(CLOSE_WRITE\): /volume1/video/Fafa.AVI
At Thu Dec 9 15:15:43 CET 2010, Autoindex ADD FILES \(CLOSE_WRITE\): /volume1/video/Fafa.AVI
At Thu Dec 9 15:15:43 CET 2010, Autoindex ADD FILES \(CLOSE_WRITE\): /volume1/video/Fafa.AVI
At Thu Dec 9 15:15:43 CET 2010, Autoindex ADD FILES \(CLOSE_WRITE\): /volume1/video/Fafa.AVI
At Thu Dec 9 15:15:43 CET 2010, Autoindex ADD FILES \(CLOSE_WRITE\): /volume1/video/Fafa.AVI
At Thu Dec 9 15:15:43 CET 2010, Autoindex ADD FILES \(CLOSE_WRITE\): /volume1/video/Fafa.AVI
At Thu Dec 9 15:15:43 CET 2010, Autoindex ADD FILES \(CLOSE_WRITE\): /volume1/video/Fafa.AVI
At Thu Dec 9 15:15:43 CET 2010, Autoindex ADD FILES \(CLOSE_WRITE\): /volume1/video/Fafa.AVI
At Thu Dec 9 15:15:43 CET 2010, Autoindex ADD FILES \(CLOSE_WRITE\): /volume1/video/Fafa.AVI
At Thu Dec 9 15:15:43 CET 2010, Autoindex ADD FILES \(CLOSE_WRITE\): /volume1/video/Fafa.AVI
At Thu Dec 9 15:15:43 CET 2010, Autoindex ADD FILES \(CLOSE_WRITE\): /volume1/video/Fafa.AVI
At Thu Dec 9 15:15:43 CET 2010, Autoindex ADD FILES \(CLOSE_WRITE\): /volume1/video/Fafa.AVI
At Thu Dec 9 15:15:44 CET 2010, Autoindex ADD FILES \(CLOSE_WRITE\): /volume1/video/Fafa.AVI


Thanks a lot ...
chtitbidule
I'm New!
I'm New!
 
Posts: 1
Joined: Thu Dec 09, 2010 2:37 pm

Re: Mediaserver indexing: correct updating (WiKi) SOLVED

Postby pachiderme » Tue Dec 21, 2010 4:14 pm

How exclude the jpg files (folder.jpg) find in the "MOVIE" directory from photo indexation because ?

I can add this exclude criteria "-name 'folder.jpg' !"

# Find all Files and exclude win files
/opt/bin/find $x -type f -wholename '*' ! -wholename */@eaDir* ! -name '*.ini' ! -name '*.db' ! -name '*.sys' ! -name '*.zip' ! -name 'folder.jpg'! -name '*.ra?' > /tmp/mediaindex/$nn.file
pachiderme
I'm New!
I'm New!
 
Posts: 3
Joined: Mon Apr 07, 2008 11:38 am

Re: Mediaserver indexing: correct updating (WiKi) SOLVED

Postby mitzone » Fri Feb 11, 2011 12:11 pm

is there a way to exclude @eaDir from inotify daemon?

the deamon (step 2) goes intoo a loop and indexes @eadir , it tells convert to create thumb for the thumbs . i'll paste a line from my log.


Feb 11 13:10:58 synothumb: synothumb.cpp (152) SYNODBFetchRow() failed
At Fri Feb 11 13:10:58 EET 2011, Autoindex REMOVE FILES: /volume1/photo/test/@eaDir/DSC00213.JPG/@eaDir/SYNOPHOTO:THUMB_B.jpg/@eaDir/SYNOPHOTO:THUMB_M.jpg/@eaDir/SYNOPHOTO:THUMB_B.jpg/t:mp.EGwgbE.jpg
At Fri Feb 11 13:10:58 EET 2011, Autoindex ADD FILES: /volume1/photo/test/@eaDir/DSC00213.JPG/@eaDir/SYNOPHOTO:THUMB_B.jpg/@eaDir/SYNOPHOTO:THUMB_M.jpg/@eaDir/SYNOPHOTO:THUMB_B.jpg/SYNOPHOTO:THUMB_L.jpg
At Fri Feb 11 13:10:58 EET 2011, Autoindex ADD DIRs: /volume1/photo/test/@eaDir/DSC00213.JPG/@eaDir/SYNOPHOTO:THUMB_B.jpg/@eaDir/SYNOPHOTO:THUMB_M.jpg/@eaDir/SYNOPHOTO:THUMB_L.jpg
At Fri Feb 11 13:10:59 EET 2011, Autoindex ADD FILES: /volume1/photo/test/@eaDir/DSC00213.JPG/@eaDir/SYNOPHOTO:THUMB_B.jpg/@eaDir/SYNOPHOTO:THUMB_M.jpg/@eaDir/SYNOPHOTO:THUMB_L.jpg/t:mp.SZULfi.jpg
At Fri Feb 11 13:10:59 EET 2011, Autoindex REMOVE FILES: /volume1/photo/test/@eaDir/DSC00213.JPG/@eaDir/SYNOPHOTO:THUMB_B.jpg/@eaDir/SYNOPHOTO:THUMB_M.jpg/@eaDir/SYNOPHOTO:THUMB_L.jpg/t:mp.SZULfi.jpg
At Fri Feb 11 13:10:59 EET 2011, Autoindex ADD FILES: /volume1/photo/test/@eaDir/DSC00213.JPG/@eaDir/SYNOPHOTO:THUMB_B.jpg/@eaDir/SYNOPHOTO:THUMB_M.jpg/@eaDir/SYNOPHOTO:THUMB_L.jpg/SYNOPHOTO:THUMB_S.jpg
At Fri Feb 11 13:11:04 EET 2011, Autoindex ADD FILES: /volume1/photo/test/@eaDir/DSC00213.JPG/@eaDir/SYNOPHOTO:THUMB_B.jpg/@eaDir/SYNOPHOTO:THUMB_M.jpg/@eaDir/SYNOPHOTO:THUMB_L.jpg/t:mp.L3UdeL.jpg
At Fri Feb 11 13:11:04 EET 2011, Autoindex REMOVE FILES: /volume1/photo/test/@eaDir/DSC00213.JPG/@eaDir/SYNOPHOTO:THUMB_B.jpg/@eaDir/SYNOPHOTO:THUMB_M.jpg/@eaDir/SYNOPHOTO:THUMB_L.jpg/t:mp.L3UdeL.jpg
At Fri Feb 11 13:11:04 EET 2011, Autoindex ADD FILES: /volume1/photo/test/@eaDir/DSC00213.JPG/@eaDir/SYNOPHOTO:THUMB_B.jpg/@eaDir/SYNOPHOTO:THUMB_M.jpg/@eaDir/SYNOPHOTO:THUMB_L.jpg/SYNOPHOTO:THUMB_M.jpg


it goes like this for 1 hour now. for a single test photo.
mitzone
Trainee
Trainee
 
Posts: 17
Joined: Sat Jan 29, 2011 2:42 pm

Re: Mediaserver indexing: correct updating (WiKi) SOLVED

Postby edraven » Tue Feb 22, 2011 5:30 am

I've followed the steps and restarted, but I've since added files and they aren't getting indexed. What steps should I take to debug?
edraven
Beginner
Beginner
 
Posts: 22
Joined: Thu Jan 27, 2011 6:16 pm

Re: Mediaserver indexing: correct updating (WiKi) SOLVED

Postby prometheus247 » Mon Apr 25, 2011 10:36 am

followed the steps including all the ipkg installation of your bunch of packages -> works perfect!
i really searched a long time for this. its a great solution!
no more rename or re-index files when they are freshly downed.

*1000 thumbs up*
prometheus247
I'm New!
I'm New!
 
Posts: 3
Joined: Thu Feb 17, 2011 12:13 pm

Next

Return to Media Streaming Mods

Who is online

Users browsing this forum: No registered users and 0 guests