自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(302)
  • 资源 (1)
  • 收藏
  • 关注

转载 munge 安装

Installing the SoftwareMUNGE requires either the Libgcrypt or OpenSSL cryptographic library. Libgcrypt is licensed under the LGPL, whereas OpenSSL is licensed under dual original-BSD-style licen

2013-01-10 09:11:07 4775

转载 Linux字符串操作函数

[zz]Linux字符串操作函数发表于1年前(1)strcat(连接两字符串)相关函数bcopy,memccpy,memcpy,strcpy,strncpy头文件#include 函数定义char *strcat (char *dest,const char *src);函数说明strcat()会将参数src字符串拷贝

2012-12-22 18:39:05 9791

原创 hostname config

NETWORKING=yes#HOSTNAME=rhel61-1HOSTNAME=vm1GATEWAY=192.168.2.1GATEWAYDEV=eth0PEERDNS=no192.168.2.200    vm1 vm1#rhel61-1# NIC 192.168.2.201    vm2 vm2#rhel61-2# NIC 19

2012-12-11 17:30:53 881

原创 vi 显示正在编辑的文件路径

正常模式下         :f   或CTRL+G 在 etc/vim/vimrc 中添加:set statusline+=%f

2012-12-06 19:22:03 4399

转载 strcat

strcatFrom Wikipedia, the free encyclopediaJump to: navigation, searchIn computing, the C programming language offers a library function called strcat that allows one memory block to b

2012-12-01 19:47:38 675

原创 pdsh+pdcp

1. pdsh-2.28.tar.bz2tar -jxvf pdsh-2.28.tar.bz2cd pdsh-2.28./configure --prefix=/usr/local --with-ssh --with-slurmmakesudo make install2. pdshpdsh -R ssh -w vm2,vm3,vm4,vm5 hostnamep

2012-11-30 15:54:40 2499

原创 salloc

1. salloc + srun[caoj7@vm1 mpi]$ salloc -N4 srun -n16 hello2. salloc + mpirun[caoj7@vm1 mpi]$ salloc -N4 mpirun -np 16 hello

2012-11-30 15:03:21 2216

原创 srun

4. srun[caoj7@vm1 soft]$ srun -n3 -l hostname1: vm20: vm22: vm2[caoj7@vm1 soft]$ srun -n4 -l /bin/hostname0: vm22: vm21: vm23: vm2[caoj7@vm1 soft]$ srun -N4 -n16 --ntasks-per-core=4 -l

2012-11-30 14:55:23 1684

原创 slurm(1): sinfo squeue scancel

1. sinfo[caoj7@vm1 soft]$ sinfoPARTITION AVAIL TIMELIMIT NODES STATE NODELISTcompute* up infinite 4 idle vm[2-5]2. squeue[caoj7@vm1 soft]$ squeue JOBID PARTITION NAME

2012-11-30 14:54:24 2761

原创 安装OpenMPI

1. 前提ssh打通2.  Make–./configure --with-devel-headers--with-slurm–make && make install•Config (~/.bashrc) »export LD_LIBRARY_PATH=/usr/local/lib:/usr/local/lib/openmpi/:$LD_LIBRARY_P

2012-11-30 10:55:30 1777

原创 安装slurm与重启slurm

1. 先安装openssl和munge 2. installInstall(caoj7)./configure --prefix=/usr/local --sysconfdir=/usr/local/etc --enable-debugmake sudomake install2. Slurm.conf (If revised, slurmctld andslu

2012-11-30 10:51:28 7592

原创 安装openssl 和配置munge

1. 安装openssl  (caoj7用户)sudo yum searchopensslsudo yum installopensslopenssl-devel2. 安装munge  (root)a)各节点之间先打通sshb)./configure --prefix=/usr/local --sysconfdir=/etc --localstatedi

2012-11-29 18:47:27 3058 1

转载 How to add a user to a group

This small how-to is to show you how to add users to existing groups, either new or existing users may be added to one or more groups at once.In all examples I will use:user: go2linux groups:

2012-11-29 16:24:35 822

转载 RedHat安装SLURM

其实和Ubuntu下面差不多的Ubuntu下配置Slurm,没有那么简单的apt-get使用,就从源码编译。参考:http://www.linuxidc.com/Linux/2012-10/71552.htmmunge的路径好像不太一样,不是/xxxx而是/usr/local/xxxx。后面还会说到这个问题。SLURM会提示出错plugin_load_from_fi

2012-11-29 15:13:17 1868

转载 VMware+Ubuntu环境安装配置SLURM

Ubuntu中ssh环境的配置ssh客户端是默认安装的,但是服务端可能要手动安装sudo apt-get openssh-server完成之后看ps -e | grep ssh看ssh-agent和sshd是否出现,出现的话就说明启动成功,其他节点就可以访问这台ubuntu了。Ubuntu中MUNGE的安装SLURM需要一个用作安全管理的插件

2012-11-29 15:12:14 2622

转载 munge installation

InstallationGuide  MUNGE Installation GuideUpdated Mar 9, 2012 by chris.m.dunlapInstalling the SoftwareMUNGE requires either the Libgcrypt or OpenSSL cryptographic library. Libgc

2012-11-27 18:36:35 1398

转载 configure error

If you having trouble compiling any application manually using “configure” , here simple fix for this error.Error ::checking whether we are using the GNU C++ compiler... nochecking whether g++ acc

2012-11-26 13:11:25 1065

原创 libevent(2) : 用libevent改写server端 实现echo_server

(1)  echo_server.clisten_event的callback函数是 do_accept_cbbev (buffer event)的三个callback函数:read_cb, write_cb, error_cb。 本例中,server端无需write_cb函数#include #include #include #include #include #i

2012-11-19 16:57:13 5714

转载 libevent (1) 入门教程:Echo Server based on libevent

http://felix021.com/blog/read.php?2068花了两天的时间在libevent上,想总结下,就以写简单tutorial的方式吧,貌似没有一篇简单的说明,让人马上就能上手用的。首先给出官方文档吧: http://libevent.org ,首页有个Programming with Libevent,里面是一节一节的介绍libevent,但是感觉信息量

2012-11-19 14:10:38 2228

转载 Linux Shell 通配符、元字符、转义符使用实例介绍

Linux Shell 通配符、元字符、转义符使用实例介绍说到shell通配符(wildcard),大家在使用时候会经常用到。下面是一个实例:?1 ?1234[chengmo@localhost ~/shel

2012-11-16 15:10:37 796

转载 What are shell wildcards

What are shell wildcards >Wildcards are a shell feature that makes the command line much more powerful than any GUI file managers. You see, if you want to select a big group of files in a graphica

2012-11-16 14:48:21 587

转载 how to c libraries

C LibrariesIn general, libraries are created from many library source files, and are either built as archive files (libmine.a) that are statically linked into executables that use them, or as shared

2012-11-15 15:20:49 860

转载 RPC远程调用编程 (1)

在查看libc6-dev软件包提供的工具(用 dpkg -L libc6-dev 命令)的时候,发现此软件包提供了一个有用的工具rpcgen命令。通过rpcgen的man手册看到此工具的作用是把RPC源程序编译成C语言源程序,从而轻松实现远程过程调用。下面的例子程序的作用是客户端程序取中心服务器上时间的,编程过程如下:先编写一个 “ RPC 语言 ” ( RPC Language (

2012-11-15 15:03:45 1219

转载 自我学会利用Linux系统上已有的开发库

http://zhoulifa.bokee.com/6094520.html1、查看库文件是由哪个软件包提供的空闲时打开/usr/lib目录(因为我知道这个目录下放着一些库文件,是我们开发者可以利用的)想看看我的系统中有哪些库。看到一个libz.so,于是用命令查看:dpkg -S /usr/lib/libz.so此命令输出如下信息:

2012-11-15 14:30:58 1668

转载 c语言之宏预处理命令

以#开头,可以放在程序的任何地方#中主要任务1》文件包含:#include#include "file.h"2>宏定义#define name body必须在一行中,否则会出现错误,可以使用延续符\,注意延续符与新行之间不能有空行,否则会导致错误a》常量定义:#define NO 9其中宏体可以使任意类型b》模拟函数:1》无参#define FLUS

2012-11-14 17:40:59 804

转载 C语言预处理命令之条件编译(#ifdef,#else,#error,#endif,#if...)

预处理过程扫描源代码,对其进行初步的转换,产生新的源代码提供给编译器。可见预处理过程先于编译器对源代码进行处理。在C语言中,并没有任何内在的机制来完成如下一些功能:在编译时包含其他源文件、定义宏、根据条件决定编译时是否包含某些代码。要完成这些工作,就需要使用预处理程序。尽管在目前绝大多数编译器都包含了预处理程序,但通常认为它们是独立于编译器的。预处理过程读入源代码,检查包含预处理指令的语句和宏

2012-11-14 17:06:28 3187

原创 字符串1

#include #include #include #define OPTIONAL 1#define MANDATORY 2char* allocate_node(size_t nodes_required, char* node_list, int flag, size_t timeout){ char *cmd[256], *flag_str[10]; if(fla

2012-11-14 15:08:30 432

原创 安装SLURM

1. 安装munge    全部用root用户, 启动。 (安装后对器重的文件夹chown -R root:root )修改用户

2012-11-13 17:39:58 695

原创 No.1: autoconf automake

1. configure.ac# -*- Autoconf -*-# Process this file with autoconf to produce a configure script.AC_PREREQ([2.68])AC_INIT([zz-test], [1.0], [amao.ch

2012-11-11 21:40:27 1506

转载 Linux编程库简介

Linux编程库简介所谓Linux编程库就是指始终可以被多个Linux软件项目重复使用的代码集。以C语言为例,它包含了几百个可以重复使用的例程和调试程序的工具代码,其中包括函数。如果每次编写新程序都要重新写这些代码会非常不方便,使用编程库有两个主要优点:可以简化编程,实现代码重复使用,进而减小应用程序的大小;可以直接使用比较稳定的代码。Linux下的

2012-11-08 20:06:12 1065

转载 利用libtool自动生成动态库的Makefile的生成方法

### 利用libtool自动生成动态库#1. autoscan命令在当前目录生成configure.scan文件, 内容为:# -*- Autoconf -*-# Process this file with autoconf to produce a configure script.AC_PREREQ(2.57)AC_INIT(

2012-11-07 16:29:16 6746

转载 Linux cgroup机制分析之框架分析

https://wiki.archlinux.org/index.php/Linux_Containers------------------------------------------ 本文系本站原创,欢迎转载!转载请注明出处:http://ericxiao.cublog.cn/------------------------------------------

2012-11-07 11:20:43 1090

转载 Cgroup

目录Cgroups是什么?Cgroups可以做什么?Cgroups相关概念及其关系相关概念相互关系Cgroups子系统介绍展开Cgroups是什么?  Cgroups是control groups的缩写,是Linux内核提供的一种可以限制、记录、隔离进程组(process groups)所使用的物理资源(如:cpu,memory,IO等等)的机制。最初由

2012-11-07 11:17:15 842

转载 常用MPI 的进程绑定方法

1. 介绍我们常通过CPU 进程绑定(binding or affinity)的方法来提高MPI 程序的性能。通过CPU 进程绑定,可以避免进程在CPU 核之间切换带来的开销,可以减轻cache 争抢现象。特别是当进程数为CPU 总核数一半左右时,有时会发现测试结果不稳定,时好时坏,很可能是因为进程切换造成的,这时不妨尝试进行进程CPU 绑定。MPI 程序的进程CPU 绑定可以

2012-11-07 09:58:28 15455 2

原创 str to int, long, float; 数字 转 字符串; 大小写转换等

#include#include#include#includeint main(){ char *str = "-1111.11";/** * double atof(const char *nptr); * int atoi(const char *nptr); * long atol(const char *nptr); * long long atoll(const c

2012-11-06 17:28:19 4863

转载 Linux下.ko, .o, .so, .a, .la文件

.o file - the unlinked output of the compiler - an object file.a - out of using ar to "pack" several .o files into an object archive file. It is an efficient way of keeping track of and being ab

2012-11-04 16:50:08 5472

原创 eclipse + autotools (1)

1. 新创建一个c语言工程auto,选用“Hello World ASCI C Autotools Project”, eclipse会调用autoscan/aclocal/ automake/autoconf自动创建一些列文件  2.  在src目录下写自己的代码,例如src/configconfig.hconfig.cconfig_test.ccontainer

2012-11-02 16:57:22 1800

转载 OOB (2)

Out Of Band (OOB) 带外数据有个不错的英文站介绍了这个OOB,http://alas.matf.bg.ac.rs/manuals/lspe/snode=125.html  带外数据,也叫紧急数据,跟普通数据没有太大区别,就是在接收时,会单独存放在一个独立缓冲中;读取时可以先被读取到(读取方式与普通数据稍有差别)。每次紧急数据只能发送一个字符。

2012-11-02 16:26:53 1931

转载 OOB (1)

OOB(out-of-band data)(综合编辑)传输层协议使用带外数据(out-of-band,OOB)来发送一些重要的数据,如过通信一放有重要的数据需要通知对方时,协议能够将这些数据快速地发送到对方.为了发送这些数据,协议一般不使用与普通数据相同的通道,而是使用另外的通道.linux系统的套接字机制支持低层协议发送和接受带外数据.但是TCP协议没有真正意义上的带外数据.为了发送重要协议

2012-11-02 16:25:03 1935

转载 makefile

支持在elcipse 以automake 方式建工程,发布的版本可以像大多数gnu 软件一样 ./confiure , make , make install 就可以搞定autotools plug-in 的功能说来弱得可怜,下面是建一个工程的步骤1、 在elcipse 中new 一个 autotools make 的工程2、手工创建automake 需要的文件 configure.a

2012-11-01 23:26:09 449

嵌入式Linux开发入门

《嵌入式Linux开发入门》全书资料及其PPT

2011-10-24

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除