localhost

Hadoop学习笔记(一)——编译安装和配置

蓝咒 提交于 2019-12-31 16:40:09
近期工作调动。打算补一下大数据处理的知识。可能会陆续涉及hadoop、mongodb、ddbs等。 首先Apache提供二进制的Hadoop版本号是32位的。在启动时总是有警告,所以想自己编译一遍。部分内容来源于网络。 0、环境说明: 操作系统环境: ububtu 14.04 LTS 64位操作系统 JDK环境: java version "1.7.0_55" Java(TM) SE Runtime Environment (build 1.7.0_55-b13) Java HotSpot(TM) 64-Bit Server VM (build 24.55-b03, mixed mode) 1、安装JDK 从ORACLE站点下载最新版本号JDK http://www.oracle.com/technetwork/java/javase/downloads/jdk7-downloads-1880260.html。选择jdk-7uXX-linux-x64.tar.gz下载。 用tar -zxvf 命令解压,解压后考到一个目录,我放到了/usr/lib/jvm。因为是測试机,仅仅有我一个人用我把JDK的环境变量配置到了 /etc/profile也能够配置到~/.bashrc加入例如以下内容 export JAVA_HOME=/usr/lib/jvm export JRE_HOME=

phpstudy搭建本地服务器访问

淺唱寂寞╮ 提交于 2019-12-31 12:38:06
搭建Apache服务器 步骤如下: 一.hosts配置: 1.用编辑器打开hosts文件,位置:C:\Windows\System32\drivers\etc目录下 2.在hosts文件里添加自己的域名配置,配置规则如下: 127.0.0.1 localhost 打开此行即可用localhost访问 127.0.0.1 域名1 127.0.0.1 域名2 .......... 配置完后,保存即可,可能需要管理员权限才能修改此文件。(记住ip地址前的'#'号一定要拿掉)。 二.apache配置: 1.编辑httpd.conf文件,开启虚拟主机,位置:在apache的安装目录,即phpstudy安装目录下的phpStudy\Apache\conf,找到Include conf/extra/httpd-vhosts.conf,去掉前面的# 2.进入开启的虚拟主机文件httpd-vhosts.conf进行域名配置,位置:\phpStudy\Apache\conf\extra目录下 配置规则: <VirtualHost *:80> ServerAdmin webmaster@dummy-host.example.com DocumentRoot "D:/phpStudy/WWW/要配置域名的项目名" ServerName 配置的域名 ErrorLog "logs/dummy-host2

How to control where Meteor runs

天涯浪子 提交于 2019-12-31 09:06:09
问题 I'm installing Meteor (framework) on my AWS EC2 (micro) instance and followed the instructions and after creating a test project I ran meteor on that directory giving me the expected [[[[[ /var/www/html/meteortest ]]]]] Running on: http://localhost:3000/ But I can't navigate to my server's localhost in my browser to see the hello world example project. Is there a way I can make meteor work on something like : http://mydomain.com/meteortest/ or http://mydomain.com/meteortest:3000 回答1: The way

How to set the DOCUMENT_ROOT and site root in my local PHP dev setup?

一个人想着一个人 提交于 2019-12-31 08:13:53
问题 I'm doing a job for a guy with a site online. It's an alien site to me, and I'm slowly working through the strange code. I have MAMP locally and my http://localhost/ has many client folders coming off from that. Inside this code there is a lot of $_SERVER['document_root'] commands and references like which are just getting lost on my local PHP dev area. How can I easily set the document_root reference to what it should be (just locally though, don't really want to mess with the site files, as

hibernate的dialect大全

岁酱吖の 提交于 2019-12-31 07:45:16
配第二个beanfactory方法: 1.下载最新版本的mssql最新驱动,把这个驱动复制到tomcat的lib下面!!这一步非常重要,耗费我两天查原因。不拷你就等着报没找到资源吧! 2.驱动加入web项目 3.添加配置文件 注意驱动类名的写法,< msql2005之前,是这么写的:(真的,这个太CNM了,也是很困扰的一件事) com.microsoft .jdbc. sqlserver . SQLServerDriver >=2005 版本之后 com.microsoft. sqlserver.jdbc .SQLServerDriver . 4.在 spring-hibernate.xml中添加另外一个sessionFactory的bean ============以下都是网络参考========================= 用得tomcat6.0配置数据库连接池 缺少msbase.jar,mssqlserver.jar,msutil.jar 并在tomcat的lib下加入上文件 和WebRoot\WEB-INF\lib下加入上文件 dbcp连接池程序包,要在同一目录下即web-inf/lib下 SQL Server2000的JDBC驱动程序的DriverClassName是 "com.microsoft.jdbc.sqlserver.SQLServerDriver"

How to allow specific IPs though the firewall? [closed]

[亡魂溺海] 提交于 2019-12-31 07:31:12
问题 Closed. This question is off-topic. It is not currently accepting answers. Want to improve this question? Update the question so it's on-topic for Stack Overflow. Closed 7 years ago . I have a local Apache server and I want it to be accessible from other machine. I found out that it's possible after turning off (the external, Windows based) firewall. Can I make it accessible from a specific IP without turning the firewall off? 回答1: Go to Windows Firewall GUI and add an exception from the

[WordPress]配置Wordpress

≡放荡痞女 提交于 2019-12-31 05:28:55
  很简单,需要php5 apache2 mysql-server wordpress。操作步骤均有注释,都写在下面的脚本中了。配置结束后访问localhost即可。 1 #- install the necessary applications 2 3 sudo apt-get install php5 apache2 mysql-server wordpress 4 5 6 #- find wordpress 7 8 locate wordpress 9 10 11 #- move to /var/www/html 12 13 cd /usr/share 14 sudo mv /usr/share/wordpress /var/www/html 15 16 17 #- configure apache2 18 #- change "DocumentRoot" -> /var/www/html/wordpress 19 20 sudo vi /etc/apache2/sites-enabled 21 22 23 #- configure mysql-server (server:localhost user:root) 24 25 mysql -h localhost -u root -p 26 CREATE USER 'kirai'@'localhost' IDENTIFIED

php curl localhost is slow when making concurrent requests

半腔热情 提交于 2019-12-31 03:33:31
问题 I have an interesting issue which I am not sure what the root cause is. I have a server and two virtual hosts A and B with ports running on 80 and 81 respectively. I have written a simple PHP code on A which looks like this: <?php echo "from A server\n"; And another simple PHP code on B: <?php echo "B server:\n"; // create curl resource $ch = curl_init(); // set url curl_setopt($ch, CURLOPT_URL, "localhost:81/a.php"); //return the transfer as a string curl_setopt($ch, CURLOPT_RETURNTRANSFER,

PHP Cookies works well on localhost, but it's not working on live server

不想你离开。 提交于 2019-12-31 03:27:06
问题 Note: This issue is already solved, finally I found that it's not cookies problem, the problem is on unserialize() function. The serialized cookie which being the parameter of that function must be stripslash-ed first. Hi there, I have a problem here about PHP Cookies. I'm using PHP Cookies to save user preferences. I've tested my code on my local machine (localhost using XAMPP). Everything's works very well, including the cookies. But when I uploaded it to the live server, the cookies not

WebAPI搭建(二) 让WebAPI 返回JSON格式的数据

孤街醉人 提交于 2019-12-31 02:31:37
在RestFul风格盛行的年代,对接接口大多数人会选择使用JSON,XML和JSON的对比传送(http://blog.csdn.net/liaomin416100569/article/details/5480825),看看这位博主是怎么说的,虽然最后没有说完,我想大概也能略微解决心中的疑惑。 1.其实要想让WebAPI 返回JSON格式的数据很简单,只要在ConfigureWebapi方法中配置一下即可。此前需要引用两个命名空间。 using Newtonsoft.Json.Serialization; using System.Linq; 2.核心代码如下: var json = config.Formatters.JsonFormatter; // 解决json序列化时的循环引用问题 json.SerializerSettings.ReferenceLoopHandling = Newtonsoft.Json.ReferenceLoopHandling.Ignore; // 移除XML序列化器 config.Formatters.Remove(config.Formatters.XmlFormatter); //设置序列化方式为驼峰命名法 var jsonFormatter = config.Formatters.OfType<System.Net.Http