ITeye博客

lg70124752的博客

lg70124752 · 共 47 篇文章

org.apache.hadoop.conf.Configuration but it is not serializable

spark job 报 org.apache.hadoop.conf.Configuration but it is not serializable 解决方案,1、如果是object类把case class 放到main外面 2、发果是在调用trait里的方法报的异常,应把case class放到trait类的外面

2015-09-09 09:10 · spark · 评论(0)

Input length must be multiple of 8 when decrypting with padded cipher

java.lang.RuntimeException: javax.crypto.IllegalBlockSizeException: Input length must be multiple of 8 when decrypting with padded cipher at us.pinguo.flume.hdfs.ext.source.BlobExtHandler.checkGeo(BlobExtHandler.java:399) at us.pinguo.flume.hdfs.ext.source.BlobExtHandler.processEvent(BlobExtHandler…

2015-06-04 09:15 · java · 评论(0)

Ubuntu下安装scikit-learn(sklearn)

按说,这个安装应该也不是很困难,但是官方网站的说明在我看来写的实在是有待改进,所以写文一篇,方便以后安装。 背景: Ubuntu 13.04 python 2 .7. 4(系统预装) 步骤: 官方原文见此链接 安装支持部分: 在terminal里面直接输入以下命令,这个命令会安装sklearn所需要的依赖,主要包括 scipy, numpy一些主流依赖。 view plaincopy在CODE上查看代码片派生到我的代码片 sudo apt-get install build-essential python-dev python-numpy python-setuptools python-…

2014-09-14 17:43 · linux python · 评论(0)

tomcat连接数查看

netstat -na | grep ESTAB | grep 8080 | wc -l

2014-05-23 11:05 · linux · 评论(0)

用linux下常用命令wget进行整站下载(递归下载至本地)

这个命令可以以递归的方式下载整站,并可以将下载的页面中的链接转换为本地链接。 wget加上参数之后,即可成为相当强大的下载工具。 wget -r -p -np -k http://xxx.com/abc/ -r, --recursive(递归) specify recursive download.(指定递归下载) -k, --convert-links(转换链接) make links in downloaded HTML point to local files.(将下载的HTML页面中的链接转换为相对链接即本地链接) -p, --page-requisites(页面必需元素) get …

2014-04-19 10:30 · linux · 评论(0)

GIT - error: Your local changes to the following files would be overwritten by m

When you see : error: Your local changes to the following files would be overwritten by merge: Execute the following : #1 - git reset --hard HEAD^ #2 - git pull .git/ yourbranch

2014-01-07 10:44 · git · 评论(0)

System.out.println((int)(char)(byte)-1) 输出为65536

这里有一条简单的规则能够描述从较窄的整形转制钱成较宽的整型时的符号扩展行为:如果最初的数值类型是有符号的,那么就执行符号扩展;如果它是char,那么不管它将要被转换成什么类型,都执行零扩展。 因为byte是一个有符号的类型,所以将byte数值-1转换成char时,会发生符号扩展。作为结果的char数值的16个位就都被置位(0)了,因此它等于2^16-1,即65536。从char到int的转型也是一个拓宽原始类型转换,所以这条规则告诉我们,它将执行零扩展而不是符号扩展。作为结果的int数值也就成了65536.

2014-01-02 14:19 · java · 评论(0)

mave 中央库

http://www.jfrog.com/confluence/pages/viewpage.action?pageId=25067914

2014-01-02 11:11 · java · 评论(0)

hadoop hbase lzo 安装

安装 LZO 压缩 1、下载LZO并解压 http://www.oberhumer.com/opensource/lzo/download/ 2、安装LZO 进入解压后的目录,执行如下命令 #./configure --enable-shared #make #sudo make install lzo文件被默认安装到了/usr/local/lib 3. 设置 LZO 库文件链接 ln -s /usr/local/lib/liblzo2.so.2 /usr/lib/liblzo2.so.2 ln -s /usr/local/lib/liblzo2.so /usr/lib/liblzo2.so…

2014-01-01 18:18 · hbase · hadoop · 评论(0)

Java 动态编译API

对于很多应用系统,常常需要动态装载和执行类和代码片断,这有利于部署的简易性和系统设计上的灵活性。本文给出了一个比较全面的介绍,值得参考。 在Sun JDK 1.2及后续版本中,包含了一组可在程序运行时刻编译和执行Java代码的API。这些API被包含在tools.jar类库中。这个功能允许Java程序在运行时动态编译、执行小的代码块,在有些情况下这个功能会让Java应用程序的架构更加灵活、开放。 本文假定读者已经在计算机中安装并配置好了Sun JDK 1.2或更高的版本,并对javac编译器命令有所了解。 在Java程序中使用编译器 假定要使用javac命令编译 /home/mytest目录…

2013-11-17 12:00 · java · 评论(0)

hbase 性能测试

1、 hbase org.apache.hadoop.hbase.PerformanceEvaluation sequentialWrite 1 详细介绍可以参见《hbase权威指南》11章 2、YCSB

2013-11-17 10:05 · hbase · 评论(0)

hbase Rolling Restarts

Unpack your release, make sure of its configuration, and then rsync it across the cluster. If you are using version 0.90.2, patch it with HBASE-3744 and HBASE-3756. Run hbck to ensure the cluster is consistent: $ ./bin/hbase hbck Effect repairs if inconsistent. Restart the master: $ ./bin/hbase-dae…

2013-11-16 22:48 · hbase · 评论(0)

Jersey Rest Service : Stream Already Closed Error

Jersey Rest Service : Stream Already Closed Error Creating File Upload functionality in WebServices using Jersey is very simple , you can go through this post to create file upload functionality in Jersey Rest Service. However , you may get an exception like this , if you are using Buffered Reader …

2013-10-17 14:21 · restful · 评论(0)

hadoop debug

export HADOOP_JOBTRACKER_OPTS="-Xdebug -Xrunjdwp:transport=dt_socket,address=878 8,server=y,suspend=y" 可使用 Hadoop 脚本中的 daemonlog 命令查看和修改某个类的日志级别,比如,可通过 以下命令查看 TaskTracker 类的日志级别: bin/hadoop daemonlog -getlevel ${tasktracker -host}:50075 org.apache.hadoop.mapred.TaskTracker Apache log4j 网址:http://lo…

2013-10-15 16:43 · hadoop · 评论(0)

日志采集

http://flume.apache.org/ http://dongxicheng.org/search-engine/scribe-intro/ http://sourceforge.net/projects/scribeserver/ https://github.com/facebook/scribe

2013-09-25 11:35 · hadoop · 评论(0)