[root@kunpeng82 ryu]# pwd /root/ryu [root@kunpeng82 ryu]# vi /etc/systemd/system/openflow.service [Unit] Description = openflow controler [Service] #ExecStart=/usr/local/bin/ryu-manager /usr/local/lib/python2.7/dist-packages/ryu/app/simple_switch_13.py ExecStart=/usr/local/bin/ryu-manager /root/ryu/ryu/ryu/app/simple_switch_13.py Restart=always Type=simple [Install] WantedBy=multi-user.target "/etc/systemd/system/openflow.service" 11L, 300C written [root@kunpeng82 ryu]# systemctl list-unit-files --type=service | grep openflow openflow.service disabled [root@kunpeng82 ryu]# systemctl start openflow [root@kunpeng82 ryu]# ps -alxg | grep ryu-manager 4 0 60138 1 20 0 167104 55104 ep_pol Ss ? 0:01 /bin/python3 /usr/local/bin/ryu-manager /root/ryu/ryu/ryu/app/simple_switch_13.py 0 0 60144 59968 20 0 110656 2496 pipe_w S+ pts/0 0:00 grep --color=auto ryu-manager
[root@kunpeng82 app]# pip3 list | grep ryu DEPRECATION: The default format will switch to columns in the future. You can use --format=(legacy|columns) (or define a format=(legacy|columns) in your pip.conf under the [list] section) to disable this warning. ryu (4.34) [root@kunpeng82 app]# pip3 show ryu Name: ryu Version: 4.34 Summary: Component-based Software-defined Networking Framework Home-page: https://ryu-sdn.org Author: Ryu project team Author-email: ryu-devel@lists.sourceforge.net License: Apache License 2.0 Location: /usr/local/lib/python3.6/site-packages Requires: eventlet, msgpack, netaddr, oslo.config, ovs, routes, six, tinyrpc, webob [root@kunpeng82 app]# ls /usr/local/lib/python3.6/site-packages/ryu app cfg.py contrib exception.py hooks.py lib ofproto services topology base cmd controller flags.py __init__.py log.py __pycache__ tests utils.py [root@kunpeng82 app]# ls /usr/local/lib/python3.6/site-packages/ryu/app/ bmpstation.py __pycache__ simple_switch_12.py simple_switch.py cbench.py rest_conf_switch.py simple_switch_13.py simple_switch_rest_13.py conf_switch_key.py rest_firewall.py simple_switch_14.py simple_switch_snort.py example_switch_13.py rest_qos.py simple_switch_15.py simple_switch_stp_13.py gui_topology rest_router.py simple_switch_igmp_13.py simple_switch_stp.py __init__.py rest_topology.py simple_switch_igmp.py simple_switch_websocket_13.py ofctl rest_vtep.py simple_switch_lacp_13.py wsgi.py ofctl_rest.py simple_monitor_13.py simple_switch_lacp.py ws_topology.py [root@kunpeng82 app]# rz -be
[root@kunpeng82 app]# cp simple_switch_13_5.py /usr/local/lib/python3.6/site-packages/ryu/app/ [root@kunpeng82 app]# /usr/local/bin/ryu-manager ryu.app.simple_switch_13_5