代码拉取完成,页面将自动刷新
一个python制作的魔术唤醒包工具
执行下面2行命令,生成安装包,然后切换到dist目录, 使用第3行命令安装包。 安装以后就可以用cmd输入wakeonlan命令测试使用。
1.python setup.py bdist_egg
2.python setup.py sdist
3.pip install wakeonlan-0.1*.tar.gz
注意:要想唤醒成功,必须把目标主机BIOS和电源相关设置弄好,具体可以百度。
>>> from wakeonlan.wakeonlan import *
>>> send_magic_packet('ff.ff.ff.ff.ff.ff')
>>> send_magic_packet('ff.ff.ff.ff.ff.ff', '00-00-00-00-00-00',
... 'FFFFFFFFFFFF')
>>> send_magic_packet('ff.ff.ff.ff.ff.ff',
... ip_address='example.com',
... port=1337)
usage: wakeonlan [-h] [-i ip] [-p port] mac address [mac address ...] Wake one or more computers using the wake on lan protocol. positional arguments: mac address The mac addresses or of the computers you are trying to wake. optional arguments: -h, --help show this help message and exit -i ip The ip address of the host to send the magic packet to. (default 255.255.255.255) -p port The port of the host to send the magic packet to (default 9)
Python3.x
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。
1. 开源生态
2. 协作、人、软件
3. 评估模型