{"id":42768,"date":"2024-10-04T03:01:27","date_gmt":"2024-10-03T19:01:27","guid":{"rendered":"https:\/\/server.hk\/cnblog\/42768\/"},"modified":"2024-10-04T03:01:27","modified_gmt":"2024-10-03T19:01:27","slug":"centos-7-%e5%ae%89%e8%a3%9d%e5%a4%a9%e6%96%87%e5%ad%b8%e5%b7%a5%e5%85%b7-presto","status":"publish","type":"post","link":"https:\/\/server.hk\/cnblog\/42768\/","title":{"rendered":"CentOS 7 \u5b89\u88dd\u5929\u6587\u5b78\u5de5\u5177 presto"},"content":{"rendered":"<h1 id=\"centos-7-%e5%ae%89%e8%a3%9d%e5%a4%a9%e6%96%87%e5%ad%b8%e5%b7%a5%e5%85%b7-presto-nzaMuWnXZx\">CentOS 7 \u5b89\u88dd\u5929\u6587\u5b78\u5de5\u5177 Presto<\/h1>\n<p>\u5728\u5929\u6587\u5b78\u7814\u7a76\u4e2d\uff0c\u6578\u64da\u8655\u7406\u548c\u5206\u6790\u662f\u81f3\u95dc\u91cd\u8981\u7684\u3002Presto \u662f\u4e00\u500b\u958b\u6e90\u7684\u5929\u6587\u5b78\u6578\u64da\u8655\u7406\u5de5\u5177\uff0c\u5c08\u9580\u7528\u65bc\u5206\u6790\u8108\u885d\u661f\u548c\u5176\u4ed6\u5929\u6587\u73fe\u8c61\u3002\u672c\u6587\u5c07\u4ecb\u7d39\u5982\u4f55\u5728 CentOS 7 \u7cfb\u7d71\u4e0a\u5b89\u88dd Presto\uff0c\u4e26\u63d0\u4f9b\u4e00\u4e9b\u57fa\u672c\u7684\u4f7f\u7528\u6307\u5357\u3002<\/p>\n<h2 id=\"%e7%b3%bb%e7%b5%b1%e8%a6%81%e6%b1%82-nzaMuWnXZx\">\u7cfb\u7d71\u8981\u6c42<\/h2>\n<p>\u5728\u5b89\u88dd Presto \u4e4b\u524d\uff0c\u78ba\u4fdd\u60a8\u7684 CentOS 7 \u7cfb\u7d71\u6eff\u8db3\u4ee5\u4e0b\u8981\u6c42\uff1a<\/p>\n<ul>\n<li>CentOS 7 \u64cd\u4f5c\u7cfb\u7d71<\/li>\n<li>\u5b89\u88dd\u4e86\u5fc5\u8981\u7684\u958b\u767c\u5de5\u5177\u548c\u5eab<\/li>\n<li>\u81f3\u5c11 1 GB \u7684 RAM<\/li>\n<li>\u8db3\u5920\u7684\u78c1\u789f\u7a7a\u9593\u4f86\u5b58\u5132\u6578\u64da\u548c\u7d50\u679c<\/li>\n<\/ul>\n<h2 id=\"%e5%ae%89%e8%a3%9d%e6%ad%a5%e9%a9%9f-nzaMuWnXZx\">\u5b89\u88dd\u6b65\u9a5f<\/h2>\n<h3 id=\"1-%e6%9b%b4%e6%96%b0%e7%b3%bb%e7%b5%b1-nzaMuWnXZx\">1. \u66f4\u65b0\u7cfb\u7d71<\/h3>\n<pre><code>sudo yum update -y<\/code><\/pre>\n<h3 id=\"2-%e5%ae%89%e8%a3%9d%e5%bf%85%e8%a6%81%e7%9a%84%e4%be%9d%e8%b3%b4%e9%a0%85-nzaMuWnXZx\">2. \u5b89\u88dd\u5fc5\u8981\u7684\u4f9d\u8cf4\u9805<\/h3>\n<p>\u5728\u5b89\u88dd Presto \u4e4b\u524d\uff0c\u60a8\u9700\u8981\u5b89\u88dd\u4e00\u4e9b\u5fc5\u8981\u7684\u4f9d\u8cf4\u9805\uff0c\u5305\u62ec GCC \u548c\u5176\u4ed6\u958b\u767c\u5de5\u5177\u3002\u53ef\u4ee5\u4f7f\u7528\u4ee5\u4e0b\u547d\u4ee4\u9032\u884c\u5b89\u88dd\uff1a<\/p>\n<pre><code>sudo yum groupinstall \"Development Tools\" -y<\/code><\/pre>\n<pre><code>sudo yum install gcc gcc-c++ make git -y<\/code><\/pre>\n<h3 id=\"3-%e4%b8%8b%e8%bc%89-presto-nzaMuWnXZx\">3. \u4e0b\u8f09 Presto<\/h3>\n<p>\u63a5\u4e0b\u4f86\uff0c\u60a8\u9700\u8981\u5f9e GitHub \u4e0b\u8f09 Presto \u7684\u6e90\u4ee3\u78bc\u3002\u4f7f\u7528\u4ee5\u4e0b\u547d\u4ee4\uff1a<\/p>\n<pre><code>git clone https:\/\/github.com\/Presto\/Presto.git<\/code><\/pre>\n<h3 id=\"4-%e7%b7%a8%e8%ad%af-presto-nzaMuWnXZx\">4. \u7de8\u8b6f Presto<\/h3>\n<p>\u9032\u5165\u4e0b\u8f09\u7684 Presto \u76ee\u9304\uff0c\u7136\u5f8c\u7de8\u8b6f\u6e90\u4ee3\u78bc\uff1a<\/p>\n<pre><code>cd Presto\nmake<\/code><\/pre>\n<h3 id=\"5-%e5%ae%89%e8%a3%9d-presto-nzaMuWnXZx\">5. \u5b89\u88dd Presto<\/h3>\n<p>\u7de8\u8b6f\u5b8c\u6210\u5f8c\uff0c\u60a8\u53ef\u4ee5\u4f7f\u7528\u4ee5\u4e0b\u547d\u4ee4\u5b89\u88dd Presto\uff1a<\/p>\n<pre><code>sudo make install<\/code><\/pre>\n<h2 id=\"%e9%85%8d%e7%bd%ae-presto-nzaMuWnXZx\">\u914d\u7f6e Presto<\/h2>\n<p>\u5b89\u88dd\u5b8c\u6210\u5f8c\uff0c\u60a8\u9700\u8981\u914d\u7f6e Presto\u3002\u9996\u5148\uff0c\u5275\u5efa\u4e00\u500b\u914d\u7f6e\u6587\u4ef6\uff1a<\/p>\n<pre><code>sudo mkdir \/etc\/presto\nsudo nano \/etc\/presto\/presto.conf<\/code><\/pre>\n<p>\u5728\u914d\u7f6e\u6587\u4ef6\u4e2d\uff0c\u60a8\u53ef\u4ee5\u8a2d\u7f6e\u6578\u64da\u76ee\u9304\u3001\u65e5\u8a8c\u76ee\u9304\u7b49\u53c3\u6578\u3002\u4ee5\u4e0b\u662f\u4e00\u500b\u57fa\u672c\u7684\u914d\u7f6e\u793a\u4f8b\uff1a<\/p>\n<pre><code>[DEFAULT]\ndata_dir = \/var\/lib\/presto\nlog_dir = \/var\/log\/presto<\/code><\/pre>\n<h2 id=\"%e9%81%8b%e8%a1%8c-presto-nzaMuWnXZx\">\u904b\u884c Presto<\/h2>\n<p>\u914d\u7f6e\u5b8c\u6210\u5f8c\uff0c\u60a8\u53ef\u4ee5\u555f\u52d5 Presto\u3002\u4f7f\u7528\u4ee5\u4e0b\u547d\u4ee4\u4f86\u904b\u884c Presto\uff1a<\/p>\n<pre><code>presto<\/code><\/pre>\n<p>\u5982\u679c\u4e00\u5207\u6b63\u5e38\uff0c\u60a8\u61c9\u8a72\u80fd\u5920\u770b\u5230 Presto \u7684\u555f\u52d5\u4fe1\u606f\uff0c\u4e26\u53ef\u4ee5\u958b\u59cb\u4f7f\u7528\u5b83\u9032\u884c\u6578\u64da\u5206\u6790\u3002<\/p>\n<h2 id=\"%e5%9f%ba%e6%9c%ac%e4%bd%bf%e7%94%a8%e6%8c%87%e5%8d%97-nzaMuWnXZx\">\u57fa\u672c\u4f7f\u7528\u6307\u5357<\/h2>\n<p>\u5728 Presto \u4e2d\uff0c\u60a8\u53ef\u4ee5\u4f7f\u7528 SQL \u8a9e\u53e5\u4f86\u67e5\u8a62\u548c\u5206\u6790\u6578\u64da\u3002\u4ee5\u4e0b\u662f\u4e00\u500b\u7c21\u55ae\u7684\u67e5\u8a62\u793a\u4f8b\uff1a<\/p>\n<pre><code>SELECT * FROM pulsar_data WHERE frequency &gt; 1000;<\/code><\/pre>\n<p>\u9019\u689d\u67e5\u8a62\u5c07\u8fd4\u56de\u6240\u6709\u983b\u7387\u5927\u65bc 1000 \u7684\u8108\u885d\u661f\u6578\u64da\u3002<\/p>\n<h2 id=\"%e7%b8%bd%e7%b5%90-nzaMuWnXZx\">\u7e3d\u7d50<\/h2>\n<p>\u5728\u672c\u6587\u4e2d\uff0c\u6211\u5011\u4ecb\u7d39\u4e86\u5982\u4f55\u5728 CentOS 7 \u7cfb\u7d71\u4e0a\u5b89\u88dd\u548c\u914d\u7f6e\u5929\u6587\u5b78\u5de5\u5177 Presto\u3002\u901a\u904e\u9019\u4e9b\u6b65\u9a5f\uff0c\u60a8\u53ef\u4ee5\u8f15\u9b06\u5730\u958b\u59cb\u9032\u884c\u5929\u6587\u6578\u64da\u7684\u5206\u6790\u3002\u5982\u679c\u60a8\u9700\u8981\u7a69\u5b9a\u7684 <a href=\"https:\/\/server.hk\">VPS<\/a> \u4f86\u904b\u884c Presto\uff0cServer.HK \u63d0\u4f9b\u591a\u7a2e\u9078\u64c7\uff0c\u9069\u5408\u4e0d\u540c\u9700\u6c42\u7684\u7528\u6236\u3002\u7121\u8ad6\u662f\u9032\u884c\u5c0f\u578b\u5be6\u9a57\u9084\u662f\u5927\u578b\u6578\u64da\u5206\u6790\uff0c\u9078\u64c7\u5408\u9069\u7684 <a href=\"https:\/\/server.hk\">\u9999\u6e2f\u4f3a\u670d\u5668<\/a> \u5c07\u6709\u52a9\u65bc\u63d0\u5347\u60a8\u7684\u5de5\u4f5c\u6548\u7387\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Learn how to install the astronomy tool Presto on CentOS 7 with this step-by-step guide for enhanced astronomical data analysis.<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[4924],"tags":[],"class_list":["post-42768","post","type-post","status-publish","format-standard","hentry","category-setup-tutorials"],"_links":{"self":[{"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/posts\/42768","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/comments?post=42768"}],"version-history":[{"count":1,"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/posts\/42768\/revisions"}],"predecessor-version":[{"id":42769,"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/posts\/42768\/revisions\/42769"}],"wp:attachment":[{"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/media?parent=42768"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/categories?post=42768"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/tags?post=42768"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}