在apache solr中使用bash脚本为卷曲建立索引数据
问题描述:
我再次发布相同的问题。请帮我解决这个问题。 下面是我写的bash脚本代码在apache solr中使用bash脚本为卷曲建立索引数据
declare -i i=1
for file in searchdumps/*
do
echo "indexing $file"
i=$((i+1))
curl "'http://localhost:8983/solr/update/extract?literal.id=document$i&uprefix=attr_content&commit=true' -F \"[email protected]/home/test/$file\""
done
的路径是正确的,当直接应用于该命令的作用,但在执行这个脚本时出现错误
索引searchdumps /次数1.pdf卷曲:(1)协议“HTTP不支持或libcurl中禁用
答
请试试这个: -
curl "http://localhost:8080/solr/update/extract?stream.file=/home/test/$file&literal.id=document$i&commit=true"
+0
好吧,我已经尝试过这个,但这个命令是不索引的文件中给出的文本。我想知道为什么我的上一个命令不起作用,并且此命令正在使用bash脚本 –
[Perl:curl:(1)Protocol'http不支持或禁用libcurl中的可能的重复](http://stackoverflow.com/questions/6684235/perl-curl-1-protocol-http-not-支持或禁用在libcurl) –