I want to run searchd deamon without any index defined.
My indexes are added dynamicly, when indexer is called with --rotate option.
When I provide config without any index i receive this output:
Sphinx 2.2.10-id64-release (2c212e0) Copyright (c) 2001-2015, Andrew Aksyonoff
Copyright (c) 2008-2015, Sphinx Technologies Inc ( http://sphinxsearch.com)
using config file 'var/sphinx.conf.in'... FATAL: no indexes found in 'var/sphinx.conf.in'
My sphinx.conf file is just:
searchd
{
log = sphinxsearchd.log
binlog_path = .
read_timeout = 5
pid_file = searchd.pid
}
Is there any way to achieve running searchd with empty index list?
Related
I am having troubles when trying to upgrade my Portable Msys2 under Win 10 with pacman -Syuu, as detailed below.
I did this before with no problem.
What could the problem and solution be?
$ pacman -Syuu
:: Synchronizing package databases...
mingw32 is up to date
mingw64 is up to date
msys is up to date
:: Starting core system upgrade...
there is nothing to do
:: Starting full system upgrade...
warning: grep: downgrading from version 3.1-1 to version 3.0-2
warning: libgc: downgrading from version 8.0.0-1 to version 7.6.8-1
warning: mingw-w64-x86_64-binutils: downgrading from version 2.31.1-2 to version 2.30-5
:: Replace mingw-w64-x86_64-minizip with mingw64/mingw-w64-x86_64-zlib? [Y/n] y
:: Replace mingw-w64-x86_64-vulkan with mingw64/mingw-w64-x86_64-vulkan-loader? [Y/n] y
resolving dependencies...
looking for conflicting packages...
Packages (217) autogen-5.18.16-1 bison-3.3.2-1 brotli-1.0.7-1 ca-certificates-20180409-1 cmake-3.13.2-1 curl-7.64.0-2 diffutils-3.7-1 doxygen-1.8.15-1
...
Total Download Size: 1400.65 MiB
Total Installed Size: 9648.15 MiB
Net Upgrade Size: 261.06 MiB
:: Proceed with installation? [Y/n] y
:: Retrieving packages...
error: failed retrieving file 'mingw-w64-x86_64-qt5-5.12.1-5-any.pkg.tar.xz' from repo.msys2.org : Operation too slow. Less than 1 bytes/sec transferred the last 10 seconds
error: failed retrieving file 'mingw-w64-x86_64-qt5-5.12.1-5-any.pkg.tar.xz' from sourceforge.net : SSL certificate problem: unable to get local issuer certificate
error: failed retrieving file 'mingw-w64-x86_64-qt5-5.12.1-5-any.pkg.tar.xz' from www2.futureware.at : Operation too slow. Less than 1 bytes/sec transferred the last 10 seconds
error: failed retrieving file 'mingw-w64-x86_64-qt5-5.12.1-5-any.pkg.tar.xz' from mirror.yandex.ru : SSL certificate problem: unable to get local issuer certificate
warning: failed to retrieve some files
error: failed to commit transaction (download library error)
Errors occurred, no packages were upgraded.
As per this, my repo configuration seems to be ok:
$ pacman-conf.exe
[options]
RootDir = /
DBPath = /var/lib/pacman/
CacheDir = /var/cache/pacman/pkg/
HookDir = /etc/pacman.d/hooks/
GPGDir = /etc/pacman.d/gnupg/
LogFile = /var/log/pacman.log
HoldPkg = pacman
Architecture = i686
CheckSpace
UseDelta = 0.000000
CleanMethod = KeepInstalled
SigLevel = PackageRequired
SigLevel = PackageTrustedOnly
SigLevel = DatabaseOptional
SigLevel = DatabaseTrustedOnly
LocalFileSigLevel = PackageOptional
LocalFileSigLevel = PackageTrustedOnly
[mingw32]
Usage = All
Server = http://repo.msys2.org/mingw/i686/
Server = https://sourceforge.net/projects/msys2/files/REPOS/MINGW/i686/
Server = http://www2.futureware.at/~nickoe/msys2-mirror/mingw/i686/
Server = https://mirror.yandex.ru/mirrors/msys2/mingw/i686/
[mingw64]
Usage = All
Server = http://repo.msys2.org/mingw/x86_64/
Server = https://sourceforge.net/projects/msys2/files/REPOS/MINGW/x86_64/
Server = http://www2.futureware.at/~nickoe/msys2-mirror/mingw/x86_64/
Server = https://mirror.yandex.ru/mirrors/msys2/mingw/x86_64/
[msys]
Usage = All
Server = http://repo.msys2.org/msys/i686/
Server = https://sourceforge.net/projects/msys2/files/REPOS/MSYS2/i686/
Server = http://www2.futureware.at/~nickoe/msys2-mirror/msys/i686/
Server = https://mirror.yandex.ru/mirrors/msys2/msys/i686/
Related:
https://github.com/msys2/MINGW-packages/issues/1887
https://bbs.archlinux.org/viewtopic.php?id=199693
https://sourceforge.net/p/msys2/discussion/general/thread/8427aab0/
EDIT
It was suggested in a comment that I execute pacman-mirrors ...
There seems to be no such executable in my system (either script, alias, etc.)
On the other hand, it seems I already have pacman-mirrors, and that it does not provide any executable (at least in msys2). Is this correct?
$ updatedb
$ locate pacman-mirrors
/var/cache/pacman/pkg/pacman-mirrors-20180604-2-any.pkg.tar.xz
/var/lib/pacman/local/pacman-mirrors-20180604-2
/var/lib/pacman/local/pacman-mirrors-20180604-2/desc
/var/lib/pacman/local/pacman-mirrors-20180604-2/files
/var/lib/pacman/local/pacman-mirrors-20180604-2/mtree
$ pacman -Ql pacman-mirrors
pacman-mirrors /etc/
pacman-mirrors /etc/pacman.d/
pacman-mirrors /etc/pacman.d/mirrorlist.mingw32
pacman-mirrors /etc/pacman.d/mirrorlist.mingw64
pacman-mirrors /etc/pacman.d/mirrorlist.msys
$ pacman --needed -S bash pacman pacman-mirrors msys2-runtime
warning: bash-4.4.023-1 is up to date -- skipping
warning: pacman-5.1.2-2 is up to date -- skipping
warning: pacman-mirrors-20180604-2 is up to date -- skipping
warning: msys2-runtime-2.11.2-1 is up to date -- skipping
You can disable the timeout of pacman with the parameter --disable-download-timeout. Then you should be able to download
http://repo.msys2.org/mingw/x86_64/mingw-w64-x86_64-qt5-5.12.1-5-any.pkg.tar.xz
It's described on the man-page for pacman.
Also --gpgdir to Specify a directory of files used by GnuPG to verify package signatures might be useful.
Additional you can consider using the parameter --noconfirm
to bypass any and all “Are you sure?” messages.
About the certificates I'm not sure, perhaps the local paths are not configured correctly. Nevertheless you've two domains, that still serve by http.
In browser the download works btw. it just has finished, the screenshot is still showing the download in progress:
I've also faced this problem but I got the solution: Open Add or Remove Softwares and go to Preferences and then change your official repositories to Canada then Refresh mirror lists
It may work now
The following were the steps I used to solve the problem;
sudo nano /etc/pacman.d/mirrorlist (to open the mirror list on manjaro or any arch based distro)
In the mirror list, all the source servers will be active. Put a hash at the beginning of each line of a selected active server to prevent the server from being contacted during the download process. You don't need all of the servers to be active, so only allow countries close to you and place a hash in front of all other servers that aren't.
## Generated on 2022-08-16 12:13
##
## Please use 'pacman-mirrors -f [NUMBER] [NUMBER]' to modify mirrorlist
## (Use 0 for all mirrors)
##
## Country : Poland
# Server = https://mirror.tuchola-dc.pl/manjaro/stable/$repo/$arch
## Country : Hungary
# Serve<p>r = http://mirror.infotronik.hu/mirrors/pub/manjaro/stable/$repo/$arch
## Country : Germany
Server = http://ftp.tu-chemnitz.de/pub/linux/manjaro/stable/$repo/$arch
## Country : Brazil
# Server = http://linorg.usp.br/manjaro/stable/$repo/$arch
## Country : Costa_Rica
# Server = https://mirrors.ucr.ac.cr/manjaro/stable/$repo/$arch
## Country : Australia
Server = http://mirror.ventraip.net.au/Manjaro/stable/$repo/$arch
## Country : Australia
Server = http://mirror.ventraip.net.au/Manjaro/stable/$repo/$arch
## Country : Germany
Server = http://ftp.rz.tu-bs.de/pub/mirror/manjaro.org/repos/stable/$repo/$arch
## Country : Germany
Server = https://repo.rhindon.net/manjaro/stable/$repo/$arch
## Country : Brazil
#Server = https://manjaro.c3sl.ufpr.br/stable/$repo/$arch
## Country : United_States
Server = https://mirror.math.princeton.edu/pub/manjaro/stable/$repo/$arch
## Country : Poland
#Server = http://mirror.chmuri.net/manjaro/stable/$repo/$arch
## Country : China
#Server = https://mirrors.sjtug.sjtu.edu.cn/manjarostable/$repo/$arch
## Country : China</p>
#Server = https://mirrors.ustc.edu.cn/manjaro/stable/$repo/$arch
## Country : Germany
Server =https://mirror.netzspielplatz.de/manjaro/packages/stable/$repo/$arch```
I'm installing Bucardo to replicate my Postgres server (10.1) on openSUSE Leap 42.3, and I have successfully complied the executable of Bucardo. When I tried bucardo install and modified the parameter as:
host:<none>
port:5432
user:aSuperUser
database:bucardo
piddir:/tmp/bucardo (already created)
Bucardo says: Postgres version is 4.8. Bucardo requires 8.1 or higher. How could this happen? I installed postgres 10, not 4.8. I also verified the version by select version(); and, there is only one postgres installation on my machine.
It seems to be fixed in master. There is a thread in the bucardo-general mailing list, that explains that you can make by yourself a couple of changes in the bucardo script or apply the diff:
diff --git a/bucardo b/bucardo index e1816f1..8e433ef 100755
--- a/bucardo
+++ b/bucardo ## -8979,7 +8979,7 ## sub install {
}
}
- if ($res !~ /(\d+)\.(\d+)(\S+)/) {
+ if ($res !~ /(\d+)\.(\d+)/) {
print "-->Sorry, unable to connect to the database\n\n";
warn $delayed_warning;
exit 1 if $bcargs->{batch}; ## -8988,10 +8988,7 ## sub install {
## At this point, we assume a good connection
## Assign the version variables
- my ($maj,$min,$rev) = ($1,$2,$3);
- ## We need to be able to handle things such as 9.2devel
- $rev =~ s/^\.//;
- $rev =~ s/(\d+)\.\d+/$1/;
+ my ($maj,$min) = ($1,$2);
$QUIET or print "Postgres version is: $maj.$min\n";
The bucardo script is in /usr/local/bin/bucardo and does not have write permissions so you must change it.
I'm using sphinx indexer to create a dictionary based on documents in my mysql db, but I can't limit the source's sql query to selected columns.
This is the command I use
indexer --buildstops dict.txt 1000 --verbose --print-queries --dump-rows listing_rows --buildfreqs listing_core -c config/development.sphinx.conf
With the following source in development.sphinx.conf, no documents are found and the dict.txt is empty
source listing_source {
type = mysql
sql_host = mysql
sql_user = sharetribe
sql_pass = secret
sql_db = sharetribe_development
sql_query = SELECT title AS title, description AS description FROM listings;
}
Output
Sphinx 2.2.10-id64-release (2c212e0)
Copyright (c) 2001-2015, Andrew Aksyonoff
Copyright (c) 2008-2015, Sphinx Technologies Inc (http://sphinxsearch.com)
using config file 'config/development.sphinx.conf'...
WARNING: key 'max_matches' was permanently removed from Sphinx configuration. Refer to documentation for details.
WARNING: key 'charset_type' was permanently removed from Sphinx configuration. Refer to documentation for details.
WARNING: key 'enable_star' was permanently removed from Sphinx configuration. Refer to documentation for details.
WARNING: key 'charset_type' was permanently removed from Sphinx configuration. Refer to documentation for details.
WARNING: key 'enable_star' was permanently removed from Sphinx configuration. Refer to documentation for details.
indexing index 'listing_core'...
building stopwords list...
SQL-CONNECT: ok
SQL-QUERY: SELECT title AS title, description AS description FROM listings;: ok
total 0 docs, 0 bytes
total 0.008 sec, 0 bytes/sec, 0.00 docs/sec
total 0 reads, 0.000 sec, 0.0 kb/call avg, 0.0 msec/call avg
total 0 writes, 0.000 sec, 0.0 kb/call avg, 0.0 msec/call avg
When I change the sql_query to return all columns, the indexer finds the expected number of documents (2) and adds them to the dictionary.
source listing_source {
type = mysql
sql_host = mysql
sql_user = sharetribe
sql_pass = secret
sql_db = sharetribe_development
sql_query = SELECT * FROM listings;
}
Output:
Sphinx 2.2.10-id64-release (2c212e0)
Copyright (c) 2001-2015, Andrew Aksyonoff
Copyright (c) 2008-2015, Sphinx Technologies Inc (http://sphinxsearch.com)
using config file 'config/development.sphinx.conf'...
WARNING: key 'max_matches' was permanently removed from Sphinx configuration. Refer to documentation for details.
WARNING: key 'charset_type' was permanently removed from Sphinx configuration. Refer to documentation for details.
WARNING: key 'enable_star' was permanently removed from Sphinx configuration. Refer to documentation for details.
WARNING: key 'charset_type' was permanently removed from Sphinx configuration. Refer to documentation for details.
WARNING: key 'enable_star' was permanently removed from Sphinx configuration. Refer to documentation for details.
indexing index 'listing_core'...
building stopwords list...
SQL-CONNECT: ok
SQL-QUERY: SELECT * FROM listings;: ok
total 2 docs, 485 bytes
total 0.008 sec, 56303 bytes/sec, 232.18 docs/sec
total 0 reads, 0.000 sec, 0.0 kb/call avg, 0.0 msec/call avg
total 0 writes, 0.000 sec, 0.0 kb/call avg, 0.0 msec/call avg
How can I limit the query to return selected columns only?
sql_query = SELECT title AS title, description AS description FROM listings;
Doesn't work because it doesn't have a document_id. Add a id column (as the first!) and it should work. You also dont need 'AS' if using same name. (* probably worked, because a id like column happened to be first :)
So just make sure include a id, and then name your columns want as fields ...
sql_query = SELECT id, title, description FROM listings
I have set the following in /home/david/conf/supervisor.conf:
[unix_http_server]
file=/home/david/tmp/supervisor.sock
[supervisord]
logfile=/home/david/tmp/supervisord.log ; (main log file;default $CWD/supervisord.log)
logfile_maxbytes=50MB ; (max main logfile bytes b4 rotation;default 50MB)
logfile_backups=10 ; (num of main logfile rotation backups;default 10)
loglevel=info ; (log level;default info; others: debug,warn,trace)
pidfile=/home/david/tmp/supervisord.pid ; (supervisord pidfile;default supervisord.pid)
nodaemon=false ; (start in foreground if true;default false)
minfds=1024 ; (min. avail startup file descriptors;default 1024)
minprocs=200
childlogdir=/home/david/tmp
[rpcinterface:supervisor]
supervisor.rpcinterface_factory = supervisor.rpcinterface:make_main_rpcinterface
[supervisorctl]
serverurl=unix:///home/david/tmp/supervisor.sock
And started supervisord:
$ supervisord -c /home/david/conf/supervisor.conf
However how come supervisorctl still uses the default http://localhost:9001 as the serverurl?
$ supervisorctl
http://localhost:9001 refused connection
supervisor>
I checked /home/david/tmp and the files supervisord.log and supervisord.pid do exist.
You should run supervisorctl with -c as well. From the documentation (my emphasis):
The Supervisor configuration file is conventionally named
supervisord.conf. It is used by both supervisord and supervisorctl. If
either application is started without the -c option (the option which
is used to tell the application the configuration filename
explicitly), the application will look for a file named
supervisord.conf within the following locations, in the specified
order. It will use the first file it finds.
$CWD/supervisord.conf
$CWD/etc/supervisord.conf
/etc/supervisord.conf
In MacOS, use brew to install
brew install supervisor
Then go to /usr/local/etc/supervisord.ini and comment these lines:
;[unix_http_server]
;file=/usr/local/var/run/supervisor.sock ; the path to the socket file
and uncomment these lines:
[inet_http_server] ; inet (TCP) server disabled by default
port=127.0.0.1:9001 ; ip_address:port specifier, *:port for all iface
Finally restart the daemon:
brew services restart supervisor
That's all you need.
To add to the valid answer above make sure you are putting your config files for the apps you want to monitor under supervisor's config folder as a subfolder called conf.d. This will depend of what method you use to install supervisor, the default package manager or easy_install.
As solution you can make symbolic link to the config file.
Like this for Mac OS:
sudo ln -sv /usr/local/etc/supervisord.ini /etc/supervisord.conf
I have been working on this for way too long and can't seem to figure it out. I am sure I have something wrong in my freetds.conf, odbc.ini or odbcinst.ini. I can connect to my mssql 2008 server using tsql, but still can't with isql or of course through php.
I am on CentOS 5.6.
Can anyone offer some assistance?
Thanks!
Shawn
This is in my sqltrace.log:
[ODBC][12249][1347850711.939084][__handles.c][459]
Exit:[SQL_SUCCESS]
Environment = 0x1b5fc6c0
[ODBC][12249][1347850711.939149][SQLAllocHandle.c][375]
Entry:
Handle Type = 2
Input Handle = 0x1b5fc6c0
[ODBC][12249][1347850711.939187][SQLAllocHandle.c][493]
Exit:[SQL_SUCCESS]
Output Handle = 0x1b5fcff0
[ODBC][12249][1347850711.939231][SQLConnect.c][3654]
Entry:
Connection = 0x1b5fcff0
Server Name = [MSSQL_DSN][length = 9 (SQL_NTS)]
User Name = [InetIndyArtsRemote][length = 18 (SQL_NTS)]
Authentication = [**********][length = 10 (SQL_NTS)]
UNICODE Using encoding ASCII 'ISO8859-1' and UNICODE 'UCS-2LE'
DIAG [01000] [FreeTDS][SQL Server]Unexpected EOF from the server
DIAG [01000] [FreeTDS][SQL Server]Adaptive Server connection failed
DIAG [S1000] [FreeTDS][SQL Server]Unable to connect to data source
[ODBC][12249][1347850711.949640][SQLConnect.c][4021]
Exit:[SQL_ERROR]
[ODBC][12249][1347850711.949694][SQLFreeHandle.c][286]
Entry:
Handle Type = 2
Input Handle = 0x1b5fcff0
[ODBC][12249][1347850711.949735][SQLFreeHandle.c][337]
Exit:[SQL_SUCCESS]
[ODBC][12249][1347850711.949773][SQLFreeHandle.c][219]
Entry:
Handle Type = 1
Input Handle = 0x1b5fc6c0
freetds.conf:
# $Id: freetds.conf,v 1.12 2007/12/25 06:02:36 jklowden Exp $
#
# This file is installed by FreeTDS if no file by the same
# name is found in the installation directory.
#
# For information about the layout of this file and its settings,
# see the freetds.conf manpage "man freetds.conf".
# Global settings are overridden by those in a database
# server specific section
[global]
# TDS protocol version
tds version = 8.0
# Whether to write a TDSDUMP file for diagnostic purposes
# (setting this to /tmp is insecure on a multi-user system)
dump file = /tmp/freetds.log
debug flags = 0xffff
dump file append = yes
# Command and connection timeouts
; timeout = 10
; connect timeout = 10
# If you get out-of-memory errors, it may mean that your client
# is trying to allocate a huge buffer for a TEXT field.
# Try setting 'text size' to a more reasonable limit
text size = 64512
[IndyArtsDB]
host = xxx.xx.xxx.xx
port = 1433
tds version = 8.0
client charset = UTF-8
ODBC.INI
[MSSQL_DSN]
Driver=FreeTDS
Description=IndyArts DB on Rackspace
Trace=No
Server=xxx.xx.xxx.xx
Port=1433
Database=DBName
ODCBINST.INI
[ODBC]
DEBUG=1
TraceFile=/home/ftp/sqltrace.log
Trace=Yes
[FreeTDS]
Description=MSSQL Driver
Driver=/usr/local/lib/libtdsodbc.so
UsageCount=1
Looking at your sqltrace.log it looks to me like an authentication error - you get that "Unexpected EOF from the server" message immediately after authenticating...
Is there any chance the remote server is blocking connections from your CentOS server, either completely or on port 1433? Any chance the "client charset = UTF-8" in your freetds.conf is causing the problem?
This is my (working) setup on an Ubuntu 12.04 (Precise Pangolin) machine.
Here is my /etc/odbc.ini file:
[xyz]
Description = XYZ Server
Driver = freetds
Database = MyDB
ServerName = xyz
TDS_Version = 8.0
And my /etc/odbcinst.ini file:
[freetds]
Description = MS SQL database access with Free TDS
Driver = /usr/lib/i386-linux-gnu/odbc/libtdsodbc.so
Setup = /usr/lib/i386-linux-gnu/odbc/libtdsS.so
UsageCount = 1
And finally my /etc/freetds/freetds.conf file:
[global]
# TDS protocol version
; tds version = 4.2
# Whether to write a TDSDUMP file for diagnostic purposes
# (setting this to /tmp is insecure on a multi-user system)
; dump file = /tmp/freetds.log
; debug flags = 0xffff
# Command and connection timeouts
; timeout = 10
; connect timeout = 10
# If you get out-of-memory errors, it may mean that your client
# is trying to allocate a huge buffer for a TEXT field.
# Try setting 'text size' to a more reasonable limit
text size = 64512
# A typical Sybase server
[egServer50]
host = symachine.domain.com
port = 5000
tds version = 5.0
# A typical Microsoft server
[egServer70]
host = ntmachine.domain.com
port = 1433
tds version = 7.0
# The XYZ database
[xyz]
host = XYZ
port = 1433
tds version = 8.0
Looks like the version numbers in FreeTDS have been changed from 8.0 to 7.1 and 9.0 to 7.2.
See http://www.freetds.org/userguide/choosingtdsprotocol.htm