Amnesia
- Apps
- Config Manager
- Cooking
- Disable taskbar thumbnails
- Disable User Account Control
- Excel
- Percentages
- SCOM
- Software registry key
- VSCode
Apps
Metronome
Sportractive
Free running app for mobile that tracks distance.
Make ISOs
Google cdburnerxp or https://cdburnerxp.se/en/home (working April 2017)
Make a bootable USB key or wipe it:
Google rufus usb or https://rufus.akeo.ie/ (working July 2017)
Config Manager
- The tool to view logs is CMTrace.exe and it's in C:\Windows and C:\Windows\CCM.
- A useful log for agent problems is C:\Windows\CCM\Logs\CcmExec.log
Cooking
Recipes to try
Rice absorption
Brown
White
Conversions
- 1/4 tsp yeast = 1gm
- 1/2 tsp yeast = 2gm
- 1/2 tsp salt = 3gm
- 1 tsp salt = 6gm
Weight / Volume
- 2.4 ltr bowl when empty = 1035gm
- 3.8 ltr bowl when empty = 1543gm
- 1 cup bread crumbs = 4 slices
Hydration
To get bread hydration:
liquid / flour x 100
I.e. If a recipe has 170gm water and 225 flour:
170 / 225 x 100 = 75% hydration
Get percentage of a number
To get the percentage of a number:
% x fixed_number / 100
I.e. To get 10% of 5000:
10 x 4194172 / 100 = 500
Temperature
Eggs
Boil the googy
- Put eggs in pan, add water and bring to boil (takes 6-7 mins).
- When boiling turn off gas and leave 3-4 mins.
Disable taskbar thumbnails
Open regedit and it's either one or both of these, (both DWORD 32-bit) and reboot.
HKEY_CURRENT_USER\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced. Set ExtendedUIHoverTime = 30000 (30 seconds. This delays the hover).
HKEY_CURRENT_USER\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Taskband. Set NumThumbnails = 0.
Disable User Account Control
- Control Panel.
- Security and Maintenance.
- Change User Account Control settings.
- Set to Never Notify.
Excel
Shortcuts
Task | Shortcut |
Delete row | Ctrl - (minus) |
Insert row | Alt + I + R |
Insert multiple rows | Select rows then Alt + I + R |
Insert column | Alt + I + C |
Insert multiple columns | Select rows then Alt + I + C |
Select row | Shift + Spacebar |
Filter | Ctrl + Shift + L |
Switch worksheets | Ctrl + Pg Up / Pg Down |
Insert worksheet | Shift + F11 |
Delete worksheet | Alt, H, D, S |
Percentages
Get percentage of a number
If you want to get a percentage of a fixed number:
% x fixed_number / 100
So to get 10% of 5000 it's:
10 x 4194172 / 100 = 500
Get percentage of 2 numbers
What percentage is 3000 of 5000?
3000 / 5000 * 100 = 60%
What percentage is 1 of 4426?
(4426 - 1) / 4426 * 100 = 99.9%
SCOM
Links
- System.OleDbProbe (Query SQL without a script - good for simple yes/no things)
- On-demand monitors
- On-demand monitors 2
- OpsMgr++
- Random stuff but good
What happens to a service monitor on a computer that doesn't have the service installed?
It won't alert with it not being installed but Health Explorer will show the service as being monitored which is misleading. I have also seen alerts generated saying the service wasn't running so keep it simple and only monitor services that are actually installed.
Will my group override work?
- Microsoft.Windows.Computer
- Microsoft.Windows.Cluster
- Microsoft.SystemCenter.HealthServiceWatcher
For the rules and monitors I want enabled, these work great but there's some classes that don't inherit nicely so the override won't work. This section contains a list of classes where I have confirmed if the override works or not when it targets the group.
Class | Comment |
Microsoft.SystemCenter.Agent | Overrides work if group contains Microsoft.Windows.Computer class. |
Microsoft.SystemCenter.HealthService |
Overrides work if group contains Microsoft.Windows.Computer class. |
Override inheritance (class, group, object)
What happens if you have an override that targets a class, group and object? This is from Microsoft:
"Overrides that apply to a class are applied first, then overrides that apply to a group, and finally overrides that apply to a specific object."
Full article here.
Rule-generated alerts
When you disable a rule that generates alerts it will not close active alerts generated by that rule. You need to close them manually.
Overrides targeting groups in sealed MPs
These don't work because of the ContextInstance attribute. You will get an error when you try to seal the mp.
Do overrides targeting a group with sub-groups work?
Yes. For example, if I have a root group called Test Root Group and it contains a sub-group called Test Sub Group that contains objects that the rule/monitor targets, an override targeting Test Root Group does "flow on" to objects in the sub-groups. I tested this successfully with the "High cpu" alert by adding a Windows Computer object to Test Sub Group.
Kick off a discovery on an agent without admin rights
I've often had the need to restart the HealthService on an agent to kick off discoveries but not had admin rights on the server. If you go to Operations Manager > Agent Details > Agents By Version there's 2 tasks that target the Health Service:
- Reload Configuration
- Flush Health Service State and Cache
I've tested both of these and not completely sure what each does but I've had more luck with Flush Health Service State and Cache so use that.
What is the default behaviour for agent and gateway failover?
Apparently agents failover to another MS automatically but gateways need to be configured manually.
Send parameters into SCOM tasks
When you send parameters into a SCOM task, it is a string type. This will mess you up if you are sending in a comma separated list as a parameter and you want to run commands against each one. Remember, it's not an array. If you need to test it, run $ParamVariable.gettype() in the task.
Management servers in maintenance mode
From what I've seen in SCOM 2016, this is what happens if all mgmt servers are in maintenance mode:
- Monitoring pretty much stops
- The most recent alert is back when MM started
- Mgmt servers and agents can't exit out of maintenance mode
Registry discovery attributes
If you make a registry discovery you need to put values in PathType and AttributeType and I can never remember them. Kev's Class.And.Discovery.Registry.* mps explain them all.
Software registry key
This is the key if you need to find software info:
HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall
VSCode
Shortcuts
Task | Shortcut |
Bookmark: Jump next | Ctrl + Alt + L |
Bookmark: Toggle | Ctrl + Alt + K |
Command palette | F1 / Ctrl + Shift + P |
Copy line | Shift + Alt + 🠉 🠋 |
Delete line | Ctrl + Shift + K |
Open settings | Ctrl + , |
Show/hide sidebar | Ctrl + B |
Word wrap | Alt + Z |
Search and replace in selection
- Select the text you want to replace.
- Ctrl + H.
- Paste your new text.
- Drag over the section you want to replace.
- Alt + L.
- Ctrl + Alt + Enter.
Tweaks
Settings.json
To open settings.json for your user account, press F1 and search for settings.json and select Preferences: Open User Settings (JSON).
The tweaks I like are listed here, just dump this into settings.json.
Disable grey background highlight when clicking on a word
- Press F1.
- Type in Open Settings (UI) and select it.
- Search for Occurrences Highlight.
- Under Editor: Occurrences Highlight untick Controls whether the editor should highlight semantic symbol occurrences.
Change XML highlight tag colour
This is already in settings.json under Tweaks but showing here in case you ever need to add manually. Update orange to whatever colour you want.
Just add this to settings.json.
"highlight-matching-tag.styles": {"opening": {
"name": {
"highlight": "orange"
}}}
Extensions
- Microsoft PowerShell
- Bookmarks - Alessandro Fragnani
- Highlight Matching Tag - vincaslt
- highlight-words - Richard Bondi
- XML Tools - Josh Johnson
Comments
Post a Comment