摘要: 通常我们会需要定时启动一些shell脚本,类似Windows中的Task Scheduler, 下面是在AWS EMR Cluster 主几点上配置的步骤: 1. 先创建一个shell脚本,将需要执行的任务写入脚本 vi testcron.sh 2. 修改该脚本的权限,添加执行权限: chmod a 阅读全文
posted @ 2019-02-20 14:53 雅槐 阅读(1596) 评论(0) 推荐(0) 编辑
摘要: 打开powershell as administrator Set-ADAccountPassword -Identity 域用户名 弹出提示框,输入旧密码 弹出提示框,输入新密码,两遍 登出 windows 用新密码登录 windows net user 域用户名 /domain -- 查看该账户 阅读全文
posted @ 2018-09-06 16:08 雅槐 阅读(11651) 评论(0) 推荐(0) 编辑
摘要: 今天遇到一个很诡异的问题,一直运行很正常的shell脚本失败了,只是昨天增加了一个参数而已。 报错信息: /bin/bash^M: bad interpreter: No such file or directory 后来发现root cause, 昨天修改文件的时候在windows中修改保存,然后 阅读全文
posted @ 2018-08-23 11:46 雅槐 阅读(284) 评论(0) 推荐(0) 编辑
摘要: 1. 递归上传文件: aws s3 cp 本地文件夹 s3://bucket-name -- recursive --region us-east-1 2. 递归下载S3上的文件夹: cd 本地下载文件夹 aws s3 cp s3://bucket-name --region us-east-1 . 阅读全文
posted @ 2018-07-25 10:09 雅槐 阅读(2775) 评论(0) 推荐(1) 编辑
摘要: 第一步:使用 fdisk -l 查看当前磁盘容量 fdisk -l 第二步: 使用 fdisk /dev/sda/ 为free space 添加新的分区 fdisk /dev/sda m :列出所有命令 n : n 是添加新的分区 p : p 是 primary, extend 3 : 这个数字根据 阅读全文
posted @ 2018-07-20 17:16 雅槐 阅读(132) 评论(0) 推荐(0) 编辑
摘要: 1. step1: 下载最新的 Java Archive # wget --no-cookies --no-check-certificate --header "Cookie: gpw_e24=http%3A%2F%2Fwww.oracle.com%2F; oraclelicense=accept 阅读全文
posted @ 2018-07-05 14:18 雅槐 阅读(250) 评论(0) 推荐(0) 编辑
摘要: 1. 在Linux上: # ssh-keygen ##一定用 id_rsa.pub # cat /root/.ssh/id_rsa.pub 2. copy 整个文件内容到剪切板 3. 打开IE登录github, 选择 Your profile 4. 选择 Edit Profile -> SSH an 阅读全文
posted @ 2018-07-04 16:53 雅槐 阅读(1810) 评论(0) 推荐(0) 编辑
摘要: 学习一段时间的大数据和容器技术,使用虚拟机搭建实验环境还是挺耗时耗力的。 一旦虚拟机坏掉了,还要重新开始。 最近发现了Vagrant, 简直好用上天,方便快捷,易用。 下面介绍如何在Windows中安装和配置Vagrant: 1. 下载安装Vagrant : https://www.vagrantu 阅读全文
posted @ 2018-05-30 16:25 雅槐 阅读(396) 评论(0) 推荐(0) 编辑
摘要: Step1: 切换用户为postgres sudo su postgres Step2: 用postgres连接postgreSQL psql -U postgres Step3: 修改postgres密码 alter user postgres with password 'new passwor 阅读全文
posted @ 2018-05-24 15:56 雅槐 阅读(945) 评论(0) 推荐(0) 编辑
摘要: 创建返回结果集类型的存储过程: CREATE OR REPLACE FUNCTION public.f_get_member_info( id integer, productname character) RETURNS SETOF record LANGUAGE 'plpgsql' COST 1 阅读全文
posted @ 2018-05-24 14:35 雅槐 阅读(3950) 评论(0) 推荐(0) 编辑