发表时间: 2008年09月20日 星期六,作者: lyhiving
分类: PHP&MYSQL
这个方法是一平告诉我的,相当的好用
如要定制的数据库名称 为 datest
那么可以在my.ini定义的data目录新建一个datest.sym的文件
datetest.sym里面的内容就是新的存储位置 如 G:\new\datest
重启MySQL即可。
如果遇到问题,要检查下原来data目录下的datest文件夹有没有删除
发表时间: 2008年08月01日 星期五,作者: lyhiving
分类: 默认分类
奥运期间,请各站长加强自己网站的信息管理,特别是一些政治敏感的,请赶快屏蔽掉。
以下为8月接到的关键字列表,有两份,里面的内容都需要作出屏蔽。请大家自行下载。
发表时间: 2008年04月01日 星期二,作者: lyhiving
分类: solr
Chinese:
Solr 跟 Lucene的中文資料不容易找,根據我自己經過多次嘗試後安裝成功的經驗在此先記錄下我自己的安裝方法,本來是以為Tomcat 5.5 跟 Tomcat 6.x 會一樣,結果發現有點小改變,但這裡因為我自己用的是Tomcat 5.5跟solr 1.2,所以暫時沒有關於Tomcat 6.x 跟 solr 1.2的詳細安裝方式,如果有人有Tomcat 6.x 跟 solr 1.2的安裝問題再發問吧.
Step 1.
Download a solr release from http://www.apache.org/dyn/closer.cgi/lucene/solr/, and extract it.
先下載 solr 壓縮檔並解壓縮到你的主機內.
Step 2.
Assuming that you extracted your solr to a folder named: apache-solr-1.2.0 (you can name it anyway and store it anywhere you want it.)
假設你的 solr 是解壓縮到 apache-solr-1.2.0 這個資料夾.
Step 3.
Stop Tomcat server.
Copy the apache-solr-1.2.0/dist/apache-solr-versionOfSolr.war to /usr/local/solr.war
(Do not put the solr.war in webapps directory)
停止 Tomcat, 先找這個資料途徑內的war檔: apache-solr-1.2.0/dist/apache-solr-xxx.war
複製這個war檔到/usr/local/ 並更名為 solr.war.
(solr.war 檔放哪都可以,就是不要放在webapps裡)
Copy the apache-solr-xxxx (or apache-solr-1.2.0 whatever the source folder is named)/example/solr directory to /usr/
複製 apache-solr-xxxx(下載後解壓縮的資料夾名稱,在此以apache-solr-xxx代表)/example/solr 這個資料夾到 /usr/
Step 4.
Creat a solr.xml under tomcat/conf/Cataline/localhost/ with the following content:
<Context docBase=”/usr/local/solr.war” debug=”0″ crossContext=”true” >
<Environment name=”solr/home” type=”java.lang.String” value=”/usr/solr” override=”true” />
</Context>
在 tomcat的 conf/Cataline/localhost/ 裡建立一個 solr.xml檔,並在內容寫上
<Context docBase=”/usr/local/solr.war” debug=”0″ crossContext=”true” >
<Environment name=”solr/home” type=”java.lang.String” value=”/usr/solr” override=”true” />
</Context>
docBase 要指定到你的solr.war的位置.
value 要指到你的 /solr/資料夾的位置.
Step 5.
Start Tomcat, and go to http://localhost(or tomcat IP)/solr/admin
If you get the solr admin page as shown on the solr wiki site, you have your solr installed and running.
啟動 Tomcat. 然後去tomcat的ip或 localhost下的 /solr/admin 頁面看看, 如果不是錯誤訊息頁面應該就安裝成功了.
Step 6.
Once you get your solr running, you can start configuring your solrconfig.xml and schema.xml of solr in solr/conf/ directory according to the guide on Solr wiki site. (Note: Don’t forget to restart your tomcat after editing solrconfig.xml or schema.xml)
solr 會跑後當然就是要根據你的需要更改設定啦. 需要設定的檔有 solrconfig.xml 跟 schema.xml兩個檔.
你可以在 /usr/solr/conf 資料夾內找到這兩個檔. 設定方法可以參考 solr wiki的網站,這裡就暫時不討論.
最重要的是要記得每次跟改後要記得重新開啟 tomcat 這樣新的設定才會被套用.
That’s it for today, I will try my best to keep this post up to date, and I will keep posting some related topics about solr.
For more detail about solr please refer to http://wiki.apache.org/solr/SolrTomcat