CentOS 7 Development environment built

Source: Internet
Author: User
Tags chmod install openssl openssl prev readline openvswitch

This article is mainly for oneself to see, for future reference.



Yum grouplist yum groupinstall "GNOME Desktop" Yum groupinstall "Development Tools" yum install cscope yum install ctags y Um install screen yum install grub-customizer yum install ncurses-devel yum install openssl-devel yum install gcc Yum Inst All gcc-c++ yum Install tmux cscope ctags screen grub-customizer ncurses-devel openssl-devel gcc gcc-c++ patch *lzo* *elf * vim-enhanced git bison readline-devel snappy-devel wget tcl tcl-devel tk tk-devel git-email autoconf automake wget http S://cdn.kernel.org/pub/linux/kernel/v4.x/linux-4.10.1.tar.xz XZ-DK llinux-4.10.1.tar.xz (decompress and keep) tar XF Linux-4.10.1.tar cd linux-4.10.1 cp/boot/config-3.10.0-514.el7.x86_64. config make menuconfig (load, save, exit) Config_ Strict_devmem=n # for Crash config_modversions=n config_uprobe_events=y config_arch_supports_uprobes=y CONFIG_UPROBES =y make to Modules_install make install # for crash Http://people.redhat.com/anderson/yum install patch Yum Install zo* Yum Install Bison yum Install  Readline-devel snappy-devel config_strict_devmem=n crash> mod-s e1000e crash> net NET_DEVICE NAME IP AD DRESS (ES) ffff88017e9da000 lo 127.0.0.1 ffff880207b98000 enp0s25 192.168.31.190 ffff88020a918000 wlp3s0.
245 ffff880214aea000 virbr0 192.168.122.1 ffff88020c730000 virbr0-nic ... size:2304 crash> px 2304 $ = 0x900 crash> E1000_adapter.napi ffff880207b98900 napi = {Poll_list = {n 
    ext = 0xffff880207b98c90, prev = 0xffff880207b98c90}, state = 8, Weight = $, Gro_count = 0, Poll = 0xffffffffa01d94d0 <e1000e_poll&gt, Poll_owner =-1, dev = 0xffff880207b98000, gro_list = 0x0 
          , SKB = 0x0, timer = {node = {node = {__rb_parent_color = 18446612141033753816, Rb_right = 0x0, Rb_left = 0x0}, expires = 0}, _softexpires = 0, Fu Nction = 0xffffffff816155a0 <napi_watchdog>, base = 0xffff88021e2525c0, state = 0 ' \000 ', Is_rel = 0 ' \000 ', start_pid =-1, star
      T_site = 0x0, Start_comm = "\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, Dev_list = { 
      Next = 0xffff880207b98060, prev = 0xffff880207b98060}, Napi_hash_node = {next = 0x0, Pprev = 0xffffffff81d7e288 <napi_hash+8>}, napi_id = 8193} # for Systemtap Https://sourceware.org/sys temtap/getinvolved.html Yum install *elf* stap-ve ' probe begin {log ("Hello World") exit ()} ' stap-c df-e ' probe SYSC all.* {if (Target () ==pid ()) log (name.)


 ". Argstr)} '
Function stm {        IF [[$# = 1]]; then                 Module=mlx5_core                 function=$1           &N Bsp     file= $dir/$1.stp         Elif [[$# = 2]]; Then                 module=$1               &N Bsp Function=$2                 file= $dir/$2.stp         Else &nbs P               return         fi         dir=/ Root/stap         mkdir-p $dir         cat << EOF > $file #!/usr/loc Al/bin/stap-v Global start Function Timestamp:long () {return Gettimeofday_us ()-start} probe begin {start = Gettimeof
Day_us ()} global i=0; Probe module ("$module"). functIon ("$function") {        Print_backtrace ()         printf ("Parms:%s\n", \$\ $par
MS);
        printf ("Execname:%s\n", Execname ());
        printf ("TS:%d\n", timestamp ()/1000000);
        Print_ubacktrace ()         printf ("%d\n", i++);  EOF set-x         cat $file         CD $dir         chmod +x $file         stap-v-k-d act_gact-d cls_flower-d act_mirred-d/usr/sbin/ethtool-d Cls_flowe r-d udp_tunnel-d sch_ingress-d/home1/chrism/iproute2/tc/tc-d 8021q-d/usr/sbin/ip-d/usr/sbin/ifconfig-d/usr/sbin /tc-d devlink-d mlx5_core-d/usr/sbin/devlink  -d vhost-d vhost_net-d tun-d kernel-d openvswitch-d vport_vxla
 n-d vxlan-d/usr/lib64/libpthread-2.17.so-d/usr/sbin/ovs-vswitchd-d/usr/lib64/libc-2.17.so $file set +x}
function str {[[$#!= 1]] && return dir=/root/stap file= $dir/$1.STP mkdir- P $dir mod=$ (grep-w $1/proc/kallsyms | awk ' {print $} ' | tr-d] | tr-d [) Echo $mod if [["$mod" = ""]]; Then cat << EOF > $file #!/usr/local/bin/stap Global start function Timestamp:long () {return g Ettimeofday_us ()-start} probe begin {start = Gettimeofday_us ()} Probe kernel.function ("$"). return {/* Print_
        BackTrace () */printf ("%x\t%d\n", \ $return, \ $return);
printf ("TS:%d\n", timestamp ()/1000000); EOF else cat << EOF > $file #!/usr/local/bin/stap Global start function Timestamp:lon G () {return Gettimeofday_us ()-start} probe begin {start = Gettimeofday_us ()} Probe module ("$mod"). Function ("$"). R
        Eturn {/* Print_backtrace () */printf ("%x\t%d\n", \ $return, \ $return);
printf ("TS:%d\n", timestamp ()/1000000); EOF fi set-x cat $file cd $dir chmod +x $file stap-v-k-d vhost-d vhost_net-d tun-d kernel-d openvswitch-d vport_vxlan-d vxlan-d/usr/lib64/libpthread-2.17.so-d 
        /usr/lib64/libc-2.17.so $file Set +x} mybuild () {set-x;
        ver=4.10.1 module=e1000e;
        linux_dir=/home/mishuang/linux-$ver;
        src_dir= $linux _dir/drivers/net/ethernet/intel/$module;
        CD $dir _dir;
        sudo make config_e1000e=m-c $linux _dir m= $src _dir modules;
        sudo cp $src _dir/$module. ko/lib/modules/$ver/kernel/drivers/net/ethernet/intel/$module;
        sudo rmmod $module;
sudo modprobe $module; Set +x} $ yum provides/etc/passwd $ rpm-qf/etc/passwd


Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.