bin

Node.js

萝らか妹 提交于 2019-11-26 23:00:28
安装 使用 nvm 安装(可以自由切换 node 版本) (1)下载并执行安装脚本 # curl curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.33.11/install.sh | bash # 或者 wget wget -qO- https://raw.githubusercontent.com/creationix/nvm/v0.33.11/install.sh | bash (2)下载并使用指定版本的 node.js # 列出仓库中所有的 node 版本 $ nvm ls-remote # 安装指定版本 $ nvm install 8.11.1 # 使用已安装的某个版本 $ nvm use 8.11.1 # 查看当前使用的 node 版本 $ nvm -v (3)卸载指定版本的 node.js # 如果要卸载的版本是当前使用的版本,那么需要先停用它 $ nvm deactivate $ nvm uninstall 8.11.1 异步编程 callback promise async/await 排错 /usr/bin/env: node: No such file or directory (1)背景:执行 npm start 命令时出现上述错误。 (2)原因: npm 执行时默认使用 /usr

MongoDB 安装及制作成windows服务

北战南征 提交于 2019-11-26 22:50:18
下载:    注: 直接使用浏览器下载速度很慢,建议使用其他下载软件下载(比如:迅雷) 官网下载地址: https://fastdl.mongodb.org/win32/mongodb-win32-x86_64-2008plus-ssl-4.0.12-signed.msi 或 进入官网( https://www.mongodb.com/ )选择下载: 安装: 文件下载完之后,直接双击运行: 这一步要选择“Custom”,下一步设置安装路径: 修改安装路径:    注: 安装路径不要有空格!比如:D:\Program Files\MongoDB\Server\4.0 中的 “Program Files” 不符合! 这一步,取消勾选安装Compass,不然会等待很久很久。我等了一个小时也没安装完。猜测是安装过程中会去官网下载compass的安装文件,下载速度很慢。 compass 官网下载地址: https://downloads.mongodb.com/compass/mongodb-compass-community-1.18.0-win32-x64.msi 如果安装了杀毒软件,后面会弹出提示框,允许即可: 这一步选择“Ignore”,忽略即可: 至此安装完成! 安装完之后进入安装目录的bin文件夹下,可看到以下文件: mongo.exe 是客户端 mongod.exe 是服务端

Read VBA macros (or vbaProject.bin) of an Excel file without opening it in MS Excel [closed]

混江龙づ霸主 提交于 2019-11-26 22:35:48
问题 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 last month . I would like to analyze Excel files, especially those which contain VBA programs inside. because I plan to run this analysis on lots of Excel files one by one, I don't want to open these files within Microsoft Excel to analyze them. One difficulty is to find and parse the VBA macros of an Excel file. We know that

failed to find romfile \"vgabios-stdvga.bin\"

半城伤御伤魂 提交于 2019-11-26 22:21:24
问题:failed to find romfile "vgabios-stdvga.bin" 解决: apt-get install vgabios ln -s /usr/share/vgabios/vgabios.stdvga.bin /usr/share/qemu/vgabios-stdvga.bin root@ostack1:/var/cache/apt/archives# ll /usr/share/vgabios/ 总用量 344 drwxr-xr-x 2 root root 4096 8月 11 09:00 ./ drwxr-xr-x 139 root root 4096 8月 11 09:00 ../ -rw-r--r-- 1 root root 41472 2月 17 2016 vgabios.bin lrwxrwxrwx 1 root root 18 2月 17 2016 vgabios-cirrus.bin -> vgabios.cirrus.bin -rw-r--r-- 1 root root 36352 2月 17 2016 vgabios.cirrus.bin -rw-r--r-- 1 root root 36352 2月 17 2016 vgabios.cirrus.debug.bin -rw-r--r-- 1 root root 42496 2月 17

启动hadoop报192.168.1.151: Address 192.168.1.151 maps to node1, but this does not map back to the addre...

我只是一个虾纸丫 提交于 2019-11-26 20:33:30
使用root用户启动hadoop的时候报错: [ root@node1 ~ ] # su - hadoop - c start -all .sh starting namenode, logging to / app / hadoop / bin / .. / logs / hadoop - hadoop - namenode - node1.out 192.168 . 1.153 : starting datanode, logging to / app / hadoop / bin / .. / logs / hadoop - hadoop - datanode - node3.out 192.168 . 1.152 : starting datanode, logging to / app / hadoop / bin / .. / logs / hadoop - hadoop - datanode - node2.out 192.168 . 1.151 : Address 192.168 . 1.151 maps to node1, but this does not map back to the address - POSSIBLE BREAK -IN ATTEMPT! 192.168 . 1.151 : starting secondarynamenode,

将Nagios监控信息存入Mysql

主宰稳场 提交于 2019-11-26 20:31:39
一、NDOUtils安装需求: nagios:安装方法: http://www.cnblogs.com/Richardzhu/p/3340638.html mysql:源码安装方法: http://www.cnblogs.com/Richardzhu/p/3220883.html DBI和DBD-mysql安装方法如下: shell > perl - MCPAN - e shell cpan > install DBI cpan > install DBD::mysql 二、关联mysql头文件和库: 不做关联可能在config或make时出错 ln - s / app / mysql / include /* /usr/include/ ln -s /app/mysql/lib/* /usr/lib/ echo '/usr/lib' >> /etc/ld.so.conf ldconfig -v 三、安装nodutils: tar zxvf ndoutils - 1 .4b7.tar.gz cd ndoutils - 1 .4b7 . / configure -- prefix=/usr/local/nagios --enable-mysql --disable-pgsql LDFLAGS=-L/app/mysql/lib --with-mysql-inc=/app/mysql

使用抽象工厂反射获取不到Dal层对象,未能加载文件或程序集......

自古美人都是妖i 提交于 2019-11-26 19:30:26
Put aside the fog and see the essence 解决问题之前,要明白问题为什么会出现 如果只想单纯的解决这个问题的话,直接把错误复制然后百度就会出现很多很多解决方案 如果你想明白为什么会出现这个错误 1、首先了解反射的机制 任何类库编译完成之后都会生成.dll文件,反射就是从当前反射所在的.dll(DBZQ.Answer.Factory.dll)文件查找.dll 2、我们来看一下程序的代码和文件 web.config DalFacoty代码 我们找到web层的bin目录下,查看一下所有的程序集 很容易就会看出来,web下的bin目录并没有DBZQ.Answer.Dal.dll 3、为什么没有DBZQ.Answer.Dal.dll? 我们可以发现web/bin下有很多dll文件,就是没有DBZQ.Answer.Dal.dll文件 为什么? 我们先看看程序中有多少层 然后和dll文件仔细对比一下,发现只有9个dll文件,少了两个(DBZQ.Answer.Test和DBZQ.Answer.Dal) DBZQ.Answer.Test只是我平时写项目时做测试用的,没有任何层调用了Test层,会不会和引用有关系? 然后我们仔细理一下调用关系 不难发现,web层无论是直接还是间接,都引用了所有层,除了Dal层,这是我们就可以大胆的猜测,可能是引用的关系 会心一笑

hex/binary string conversion in Swift

独自空忆成欢 提交于 2019-11-26 19:12:52
Python has two very useful library method (binascii.a2b_hex(keyStr) and binascii.hexlify(keyBytes)) which I have been struggling with in Swift. Is there anything readily available in Swift. If not, how would one implement it? Given all the bounds and other checks (like even-length key) are done. Martin R Data from Swift 3 has no "built-in" method to print its contents as a hex string, or to create a Data value from a hex string. "Data to hex string" methods can be found e.g. at How to convert Data to hex string in swift or How to print the content of a variable type Data using swift? or

Centos下安装nexus maven私服

假如想象 提交于 2019-11-26 18:43:52
最近我从北京离职来到上海,进入一家新公司,发现这家公司的项目很糟糕,不仅代码写的很随意(可能是这个项目原来是一个人写的原因的吧,不多吐槽别人的代码风格),而且项目竟然是半maven工程,一些公司内部的jar是直接在项目中引用的,我接到这个项目的时候内心是懵逼的,整了整整一天才把这个项目跑起来,十分的蛋疼。今天终于有时间将项目改造一下,尝试搭建一台maven私服,将内部jar包扔到私服上去,方便开发,后期项目改造的服务化jar包也将扔到私服上去 1,准备工作 操作系统:centos7.0 nexus:nexus-2.14.8-01-bundle 首先直接去nexus官网下载软件包,地址:https://www.sonatype.com/download-oss-sonatype 进入官网之后,拉到最下面: 点击下载tar.gz版本,我这里直接给出地址: https://sonatype-download.global.ssl.fastly.net/repository/repositoryManager/oss/nexus-2.14.8-01-bundle.tar.gz 在centos上,用wget命令将安装包下载下来: wget https://sonatype-download.global.ssl.fastly.net/repository/repositoryManager

CentOs 6.5 使用nexus创建maven私服

不问归期 提交于 2019-11-26 18:42:45
1.私服的重要性,在实际开发中,我们会用到许多的jar包,我们不能每次开发都要拷出一堆的jar让大家分享然后下载使用 2.如果每个人都去中央仓库下载jar包这样就需要很多的带宽,然后还浪费大家的时间 这里我们在自己本地服务器使用nexus搭建一个maven中央仓库。这里使用的环境是CentOS 6.5,jdk是jdk1.7.0_75,至于为什么是1.7版本的jdk,因为是高版本的jdk和nexus启动不了。 先说jdk的配置,我这里选择的root用户配置jdk,是整个用户的jdk环境变量,至于jdk怎么上传到服务器,还有哪儿下载,这里不做重复! 如图,解压jdk 命令 tar -zxvf 这是我将jdk放在了opt文件下,至于放哪儿,是关系到配置路径的问题,编辑 vi /etc/profile,在其中加入如下所示 其中的路径就是你解压之后放置文件的路径, export MAVEN_HOME=/home/nexus_user/apache-maven-3.3.1 export JAVA_HOME=/opt/jdk1.7.0_75 export GRADLE_HOME=/usr/local/gradle-2.2.1 export PATH=$JAVA_HOME/bin:$MAVEN_HOME/bin:$GRADLE_HOME/bin:$PATH export CLASSPATH=.: