Nie jesteś zalogowany.
Jeśli nie posiadasz konta, zarejestruj je już teraz! Pozwoli Ci ono w pełni korzystać z naszego serwisu. Spamerom dziękujemy!
Prosimy o pomoc dla małej Julki — przekaż 1% podatku na Fundacji Dzieciom zdazyć z Pomocą.
Więcej informacji na dug.net.pl/pomagamy/.
Strony: 1
witam, dawno już tutaj nie zaglądałem ;) mam problem z filtrami mieszającymi - mianowicie mam coś takiego:
/sbin/tc qdisc add dev eth1 root handle 1: hfsc default 2 /sbin/tc class add dev eth1 parent 1: classid 1:1 hfsc ls m2 24000kbit ul m2 24000kbit /sbin/tc class add dev eth1 parent 1: classid 1:2 hfsc ls m2 128kbit ul m2 256kbit /sbin/tc filter add dev eth1 protocol ip prio 1 parent 1: handle 8: u32 divisor 256 /sbin/tc filter add dev eth1 protocol ip prio 1 parent 1: u32 ht 800: match ip dst 192.168.50.0/24 hashkey mask 0x000000ff at 16 link 8: /sbin/tc class add dev eth1 parent 1:1 classid 1:5 hfsc ls m2 128kbit /sbin/tc filter add dev eth1 protocol ip parent 1: u32 ht 8:0xa match ip dst 192.168.50.10 flowid 1:5 /sbin/tc class add dev eth1 parent 1:5 classid 1:640 hfsc sc d 30ms m2 15kbit ul m2 25kbit /sbin/tc filter add dev eth1 protocol ip prio 1 parent 1: u32 ht 8:0xa match ip protocol 1 0xff flowid 1:640 /sbin/tc class add dev eth1 parent 1:5 classid 1:641 hfsc sc d 20ms m2 15kbit ul m2 100kbit /sbin/tc filter add dev eth1 protocol ip prio 2 parent 1: u32 ht 8:0xa match ip protocol 6 0xff match u8 0x05 0x0f at 0 match u16 0x0000 0xffc0 at 2 match u8 0x10 0xff at 33 flowid 1:641 /sbin/tc class add dev eth1 parent 1:5 classid 1:642 hfsc ls m2 10kbit ul m1 1500kbit d 5000ms m2 500kbit /sbin/tc filter add dev eth1 protocol ip prio 3 parent 1: u32 ht 8:0xa match ip sport 80 0xffff flowid 1:642 /sbin/tc class add dev eth1 parent 1:5 classid 1:643 hfsc ls m2 10kbit ul m2 400kbit /sbin/tc filter add dev eth1 protocol ip prio 4 parent 1: u32 ht 8:0xa match ip dst 0.0.0.0/0 flowid 1:643 /sbin/tc class add dev eth1 parent 1:1 classid 1:6 hfsc ls m2 128kbit /sbin/tc filter add dev eth1 protocol ip parent 1: u32 ht 8:0xb match ip dst 192.168.50.11 flowid 1:6 /sbin/tc class add dev eth1 parent 1:6 classid 1:644 hfsc sc d 30ms m2 15kbit ul m2 25kbit /sbin/tc filter add dev eth1 protocol ip prio 1 parent 1: u32 ht 8:0xb match ip protocol 1 0xff flowid 1:644 /sbin/tc class add dev eth1 parent 1:6 classid 1:645 hfsc sc d 20ms m2 15kbit ul m2 100kbit /sbin/tc filter add dev eth1 protocol ip prio 2 parent 1: u32 ht 8:0xb match ip protocol 6 0xff match u8 0x05 0x0f at 0 match u16 0x0000 0xffc0 at 2 match u8 0x10 0xff at 33 flowid 1:645 /sbin/tc class add dev eth1 parent 1:6 classid 1:646 hfsc ls m2 10kbit ul m1 1500kbit d 5000ms m2 500kbit /sbin/tc filter add dev eth1 protocol ip prio 3 parent 1: u32 ht 8:0xb match ip sport 80 0xffff flowid 1:646 /sbin/tc class add dev eth1 parent 1:6 classid 1:647 hfsc ls m2 10kbit ul m2 400kbit /sbin/tc filter add dev eth1 protocol ip prio 4 parent 1: u32 ht 8:0xb match ip dst 0.0.0.0/0 flowid 1:647
może mi ktoś powiedzieć dlaczego jestem wrzucany w domyślną kolejkę?
Offline
dobra sprawa już ogarnięta, ostatecznie wygląda to tak:
#!/bin/bash /sbin/tc qdisc del root dev eth1 /sbin/tc qdisc add dev eth1 root handle 1: hfsc default 2 /sbin/tc filter add dev eth1 parent 1: protocol ip u32 /sbin/tc class add dev eth1 parent 1: classid 1:1 hfsc ls m2 24000kbit ul m2 24000kbit /sbin/tc class add dev eth1 parent 1: classid 1:2 hfsc ls m2 128kbit ul m2 256kbit /sbin/tc filter add dev eth1 parent 1: prio 1 handle 8: protocol ip u32 divisor 256 /sbin/tc filter add dev eth1 protocol ip parent 1: prio 1 u32 ht 800:: match ip dst 192.168.50.0/24 hashkey mask 0x000000ff at 16 link 8: /sbin/tc class add dev eth1 parent 1:1 classid 1:5 hfsc ls m2 128kbit /sbin/tc class add dev eth1 parent 1:5 classid 1:640 hfsc sc d 30ms m2 20kbit ul m2 25kbit /sbin/tc filter add dev eth1 protocol ip prio 1 parent 1: u32 ht 8:0xa: match ip protocol 1 0xff flowid 1:640 /sbin/tc class add dev eth1 parent 1:5 classid 1:641 hfsc sc d 20ms m2 15kbit ul m2 100kbit /sbin/tc filter add dev eth1 protocol ip prio 2 parent 1: u32 ht 8:0xa: match ip protocol 6 0xff match u8 0x05 0x0f at 0 match u16 0x0000 0xffc0 at 2 match u8 0x10 0xff at 33 flowid 1:641 /sbin/tc class add dev eth1 parent 1:5 classid 1:642 hfsc ls m2 20kbit ul m2 10000kbit /sbin/tc filter add dev eth1 protocol ip prio 3 parent 1: u32 ht 8:0xa: match ip sport 80 0xffff flowid 1:642 /sbin/tc class add dev eth1 parent 1:5 classid 1:643 hfsc ls m2 10kbit ul m2 4000kbit /sbin/tc filter add dev eth1 protocol ip prio 4 parent 1: u32 ht 8:0xa: match ip dst 0.0.0.0/0 flowid 1:643 /sbin/tc class add dev eth1 parent 1:1 classid 1:6 hfsc ls m2 128kbit /sbin/tc class add dev eth1 parent 1:6 classid 1:644 hfsc sc d 30ms m2 20kbit ul m2 25kbit /sbin/tc filter add dev eth1 protocol ip prio 1 parent 1: u32 ht 8:0xb: match ip protocol 1 0xff flowid 1:644 /sbin/tc class add dev eth1 parent 1:6 classid 1:645 hfsc sc d 20ms m2 15kbit ul m2 100kbit /sbin/tc filter add dev eth1 protocol ip prio 2 parent 1: u32 ht 8:0xb: match ip protocol 6 0xff match u8 0x05 0x0f at 0 match u16 0x0000 0xffc0 at 2 match u8 0x10 0xff at 33 flowid 1:645 /sbin/tc class add dev eth1 parent 1:6 classid 1:646 hfsc ls m2 20kbit ul m2 10000kbit /sbin/tc filter add dev eth1 protocol ip prio 3 parent 1: u32 ht 8:0xb: match ip sport 80 0xffff flowid 1:646 /sbin/tc class add dev eth1 parent 1:6 classid 1:647 hfsc ls m2 10kbit ul m2 4000kbit /sbin/tc filter add dev eth1 protocol ip prio 4 parent 1: u32 ht 8:0xb: match ip dst 0.0.0.0/0 flowid 1:647
Offline
pytanie bo nie mogę tego nigdzie w opisach znaleźć.
jaka jest różnica między "sc" a "ls"?
rt - jasne, real-time, ul - czyli ile max może pożyczyć od innych, ls - czyli minimum, ale co daje nam "sc"?
--edited
za bardzo się pośpieszyłem. sc = "rt + ls"
Ostatnio edytowany przez Nicram (2014-01-14 22:18:06)
Offline
Strony: 1
Time (s) | Query |
---|---|
0.00010 | SET CHARSET latin2 |
0.00003 | SET NAMES latin2 |
0.00128 | SELECT u.*, g.*, o.logged FROM punbb_users AS u INNER JOIN punbb_groups AS g ON u.group_id=g.g_id LEFT JOIN punbb_online AS o ON o.ident='13.59.87.145' WHERE u.id=1 |
0.00065 | REPLACE INTO punbb_online (user_id, ident, logged) VALUES(1, '13.59.87.145', 1732430523) |
0.00068 | SELECT * FROM punbb_online WHERE logged<1732430223 |
0.00076 | DELETE FROM punbb_online WHERE ident='18.219.15.112' |
0.00078 | DELETE FROM punbb_online WHERE ident='3.135.184.27' |
0.00086 | SELECT topic_id FROM punbb_posts WHERE id=247532 |
0.00100 | SELECT id FROM punbb_posts WHERE topic_id=24760 ORDER BY posted |
0.00065 | SELECT t.subject, t.closed, t.num_replies, t.sticky, f.id AS forum_id, f.forum_name, f.moderators, fp.post_replies, 0 FROM punbb_topics AS t INNER JOIN punbb_forums AS f ON f.id=t.forum_id LEFT JOIN punbb_forum_perms AS fp ON (fp.forum_id=f.id AND fp.group_id=3) WHERE (fp.read_forum IS NULL OR fp.read_forum=1) AND t.id=24760 AND t.moved_to IS NULL |
0.00009 | SELECT search_for, replace_with FROM punbb_censoring |
0.00077 | SELECT u.email, u.title, u.url, u.location, u.use_avatar, u.signature, u.email_setting, u.num_posts, u.registered, u.admin_note, p.id, p.poster AS username, p.poster_id, p.poster_ip, p.poster_email, p.message, p.hide_smilies, p.posted, p.edited, p.edited_by, g.g_id, g.g_user_title, o.user_id AS is_online FROM punbb_posts AS p INNER JOIN punbb_users AS u ON u.id=p.poster_id INNER JOIN punbb_groups AS g ON g.g_id=u.group_id LEFT JOIN punbb_online AS o ON (o.user_id=u.id AND o.user_id!=1 AND o.idle=0) WHERE p.topic_id=24760 ORDER BY p.id LIMIT 0,25 |
0.00077 | UPDATE punbb_topics SET num_views=num_views+1 WHERE id=24760 |
Total query time: 0.00842 s |