Hello and welcome to the session. This is Professor Farhad in which we would look at journal entries and preparing financial statements from A to Z. The reason I say from A to Z, because we're going to be preparing those financial statements based on the journal entries. So this exercise is very beneficial for students who are taking financial accounting and students who are preparing for the CPA exam using the FAR section as well. Farhadlectures.com is a supplemental tool that will help you if you're studying for your CPA or your accounting courses. Now what is the difference between Farhadlectures and your typical CPA prep course? In your CPA prep course, they assume a certain level of knowledge and accounting. I don't assume anything. I teach you the material from scratch. So I don't replace your CPA course. I help you learn the basics, fill in those gaps that you did not learn in college or you learned a long time ago and you need to brush up on it. So please visit farhadlectures.com if you are a CPA candidate. As always, I would like to remind you to connect with me on LinkedIn. If you haven't done so, YouTube is where you would need to subscribe. I have 1,800 plus accounting, auditing, tax, finance, as well as Excel tutorials. If you like my lectures, please like them and share them, connect with me on Instagram, like my Facebook page. Always, I'm going to remind you to go to farhadlectures.com for additional resources for your CPA, accounting, and finance courses. So this is what we are going to be doing. This looks very intimidating. We're going to take this step by step. We have a company, ARC, that was formed on January 1st, 2014. And we have those transaction A through H. I'm going to go over each transaction separately. I'm going to break them down transaction by transaction. We're going to go over each transaction separately. Then we are going to prepare the income statement. We're going to prepare the balance sheet. We're going to prepare the statement of cash flow using the indirect method. Lot of information. This is basically a big portion of your financial accounting 101. So you have to know where each transaction goes. You have to know basic journal entries. Let's go ahead and get started by analyzing those transaction, looking at the first transaction. On January 1st, ARC issued no-par common stock for 450,000. And usually this is the first transaction when the company is created. When the company is created, they issue stocks to the investor. So the investor contribute money. So what happened? Cash is increased. Cash is a debit. So we're going to debit cash 450,000 and cash is a balance sheet account. So cash is a balance sheet account and we increase common stock. Common stock is a credit. We increase common stock. If you don't know your debits and your credits, go and check out my tutorial for debits and credits. Common stock is also a balance sheet account. Both of these are balance sheet account. Now what I suggest you do is something like this. Keep track of your cash. Now we have $450,000 in cash and keep track of your common stock. I'm just going to tell you, we're not going to be changing common stock, but we're going to be changing cash a lot. Second, after the company received the cash and the company started early in January, the IRC made the following cash payment. They paid for fixture, for store fixture, 53,000. So we're going to debit. We're going to increase debiting store furniture, which is an asset, which it goes on the balance sheet. And by the way, cash is also an asset. I don't have to tell you this, but maybe I have to. And common stock is equity. And the reason I'm doing this because these are going to end up on different financial statements. So you need to know what goes where. We paid for merchandise, 340,000. That's also an asset. And it goes on the balance sheet and that's increasing, it's a debit. We paid for rent on a building 20,000. Rent is an expense. Expenses goes on the income statement and it's an expense. And we paid all of those in cash. Therefore, we credit cash 413. So notice, we debited cash for 50, cash went up, then we paid cash 413, cash went down. Now, if we want to, we can keep track of our balance, the difference between those two, which will be a debit balance. Later in the year, ARC purchased inventory on account, more inventory for 239,000. Well, we debit inventory if we bought more inventory. So notice what you have to do, keep track of your inventory account as well. Credit accounts payable. Also what we need to do, keep track of accounts payable, which we have 239,000. It means we bought them and we're gonna pay it later. Okay? Before year end, ARC paid 139,000 on account for the payable. So we paid 139,000. And by the way, ignore this, we're gonna do this on a different page. So when we paid the accounts payable, we debit accounts payable, 139. Now what we have of accounts payable is really only 100,000 remaining. And we reduce cash. We credit cash because we paid our payable with cash. This is a balance sheet. This is a balance sheet. This is a balance sheet. This is a balance sheet. They're all balance sheet. This is an asset. This is a liability. Obviously this is a liability. And obviously this is an asset. And why do I need to remind you? Because at the end, we have to prepare the financial statements. During the year, ARC sold 2,400 units of merchandise for $275 each. So we debit account receivable credit sales. Why? We sold 2,400 units at 2,75. And that's gonna give us 660,000. We increase account receivable, which is an asset on the balance sheet. And we increase sales, which is an income statement account, which is a sales account. So we debit account receivable credit sales. Now, before year end, the company collected 85% of the amount of the cash. Well, if we take 660,000 of account receivable, multiplied by 85%, it's gonna give us 561. Therefore, they paid us cash 561. So cash will go up. It's a debit. And account receivable will go down, which a credit. Again, cash is an asset. It goes on the balance sheet. Account receivable is an asset. It goes on the balance sheet. Now bear in mind, hopefully you are keeping track of your cash because it's going up and down, up and down. We're gonna see what the balance is at the end. The store employs three people. Oh, sorry. We missed some information here. Also, what they told us at this point, they told us that cost of goods sold, cost of goods sold is 250,000. So they told us here cost of goods sold is 250, and ending inventory is 329. So they did the count of ending inventory and they find out ending inventory 329, and cost of goods sold, which is an expense account is 250. So this is information that we're gonna be using later on on the financial statements. The store employs three people. The combined annual payroll is 96,000, of which ARC still owes 3,000. Therefore, salary expense is 96,000. They paid 93,000 in cash and remaining a salary spable because it's not paid. So this is an expense, this is an asset, and this is a liability expenses go up, cash goes down, liability goes up. Liabilities go up because it gets a credit, okay? At year end, the company paid their income tax of 17,000. We paid it in cash. Debit income tax expense, credit cash. This is an expense and this is an asset. This goes on the income statement. This end up on the balance sheet. The cash end up on the balance sheet. Late in the year, ARC paid dividend of 44,000. We debit dividend, credit cash of 44,000. Dividend is an equity account to be more specifically retained earnings account, but it's an equity account, cash is an asset. For store fixture, ARC uses the straight line depreciation method over five years with zero of salvage value. Now we have to know how much we paid for the office furniture. Let's go back and find out how much we paid for the office furniture. We paid for the office furniture, 53,000. It's gonna be depreciated over five years. So each year, if my math is right is 10,600. If my math is right, let's see if I, if my math is right and 10,600, my math is right. So I debit depreciation expense, which is an expense account goes on the income statement, credit accumulated depreciation, which is a Contra asset account, a Contra asset that goes on the balance sheet. Now I am ready to prepare my financial statements. The first financial statement you prepare is the income statement, the name of the company, income statement and year ended December 31st, 2024. First, you list revenues. How much would our revenues? Well, we sold 2,400 unit times 275. This is total revenues. Then you list your expenses, cost of goods sold. This was giving in the problem, salaries and wages, depreciation, rent expense and income tax expense. You should be familiar with all these numbers because we did process those journal entries. Our total expenses, 393, notice we single underline to add up all the expenses. Then we take revenues minus expenses to give us net income. Notice we double underline the last number, which is 266,400. Now remember, from this net income, 266,400, we paid 40,000 and, I'm sorry, not 40, we paid, how much did we pay in dividend? Let me go back and check. We paid in dividend, 44,000. So for this number, we're gonna be subtracting 44,000. Okay, so it's gonna give us 2,200 to 400 and that's gonna be retained earnings. The earnings that we kept retained because we made 266,400 from operating the business, then we paid dividend of 44,000. Therefore, net income minus dividend keeps you with retained earnings, which is, we're gonna see this number later on on the balance sheet. Let's look at the balance sheet, same thing. We have the name of the company, the name balance sheet, then the date. So notice the date here is a point in time. It means it's a date for one day, December 31st. Versus the income statement, it says year and December 31st. So these numbers reflect the whole activities throughout the year. The balance sheet numbers shows just the date of December 31st. First, we list our current assets, which include cash. Now how did we end up with cash? Well, the best thing to do is to go back, look at your cash account, every time is debited, you debit, every time is credited, you credit. And at the end, you're gonna see this number, 305. You can check that out yourself. Account receivable, we sold 660,000. We received 85% remaining uncollected, this 15, that's gonna constitute account receivable, 99,000. Our merchandise inventory, this number was given, 329. Therefore, total current assets, 733. Property, plant, and equipment, we only had store fixture, and it was depreciated at 10,500. Remember, we call this number, book value. Current assets plus the property, plant, and equipment gives us total asset of 775,400. Our liabilities, starting with current liabilities, we had account spable of 100,000. We purchased 239 on account. We paid 139, the remaining is 100,000. We had salary spable of 3,000. Total current liabilities is 103. Then we have stockholders' equity. We have common stock of 450. This is the first transaction. Retained earning is 220,400. I showed you how we came up with that number. Retained earning, which was net income minus dividend. And stockholders' equity total of 672,400, 103, plus 672,400 equal to 775,500, which is equal to assets. So notice assets equal to liabilities plus owners' equity. Now we still have one financial statement to complete, and that's the cash flow statement. Now remember, for this company, the prior year is everything is zero. So the prior year for account receivable is zero, merchandise inventory is zero. Everything is zero for the prior year because the company started this year. So how do we complete the cash flow statement? I have plenty of tutorial about the cash flow statement, but this is just an exercise. So again, we prepare the headings with year end, just like the income statement, the cash flow statement. And what we do in the cash flow statement, we are converting net income to cash net income. Therefore, we start with net income. Net income is 266,400. Then we make certain adjustments to reconcile, starting with any non-cash expenses. Depreciation expense is an expense that's considered non-cash. It means we took the expense, but it did not reduce our cash. Therefore, we add depreciation expense. Then account receivable went up. When account receivable went up, it means your cash flow goes down. It means you sold on account, but you did not receive 99,000.  It means you sold, but you did not receive the money. The opposite would have been true.  It means you collected more cash than what you sold, okay? So account receivable went up. Your cash flow goes down. Your everything's here. Everything's gonna go up because this is the first year. Inventory went up. Again, if your inventory went up, it means you purchased more inventory than you sold, 329, increase in accounts payable. When your liabilities, when your current liabilities goes up, your cash flow goes up. Why? Because you are buying and you're not paying. Therefore, you have more cash. Therefore, it's a positive. Again, you have to go to my cash flow tutorial to see those. Again, increase in salaries payable. It means you are expensing the salaries, but you're not paying them. Remember, we owe the employees 3,000. So therefore, we add them all up. We take net income minus 3,14,400 and we have net cash used. From a cash flow perspective, we used more money than we generated. From a cash flow, really, we didn't do very well, right? From a cruel perspective, we generated positive net income, but from a cash flow, we were not good. So this is the first section, which is the operating section. The second section is the investing section. And under the investing section, the only thing is we acquire the store furniture of 53,000. Therefore, we used money for investing of 53,000. The last section is the financing section. Here, we issued stocks. So we received money from issuing stocks, but we paid some dividend. We really had no debt, no loans. Therefore, net cash is provided. So what happened is we are getting cash from investors to finance the operating as well as the investing section. Then we take the net of these three. The net of these three is operating, investing and financing. And we know that our cash netting those three is plus a 305, plus zero, the beginning cash. We didn't, the company did not exist. Therefore, the ending cash is 305. And let's look at the balance sheet. Cash is 305. Notice cash is 305. Therefore, it works. Therefore, our balance sheet worked. So this was an exercise. This was an exercise that went through journal entries, financial statements, and cash flow statement. I might have went a little bit fast because this is not for explanation purposes. This is just a review. Assuming you went through the tutorial for journal entries, you went to the tutorial through how to prepare an income statement, balance sheet statement of cash flow. Anyhow, if you need more resources for your courses, check out my website, farhatlectures.com. If you're studying for your CPA exam, look, you need to learn the basic. You need to invest in your career. Check out my website. CPA is a lifetime investment. Study hard, stay safe.


Good morning everyone, we are first day morning at Long Beach. I don't have my motorhome so I'm in my auto room and gonna get to do some DHL visit this morning, one for the retailer and another one with some people that are coming to our shop and then back to the track, track walk What's the weather doing like? Yeah, decent view. Race track is just around there. Oh actually the race track is here on the right hand side where the coons are. It's a bit gray, it's a bit fresh in California That's gonna be a good day. Here we are just finished DHL event It's raining in California and actually raining a lot and it's very cold Quite funny heading back to Long Beach now, but that was fun to meet to meet a lot of fans that came out. Here we go getting to the paddock with downtown car park behind me track in front of me I'm gonna sneak to the paddock Engine meeting and then track walk. I'm gonna take you through the lap I'll show you some of the cool stuff around Long Beach. I guess I did pretty well last year So I know some cool stuff and I'll try to explain to you what we look for and what the difference is and What's good in Long Beach? This turn is pretty fun to aim It's pretty tight so you change a bit inside But yeah, you really want to put your your wheel there on the apex. That's where the grip is and it's pretty tight on the exit as well It's gonna be five and six I believe. Five here. Still gonna get cornered pretty fast Opens a bit on exit and then I'll show you the next one which is a tricky one Here we go next right corner questions always being do we use the inside curb or not? Now you can actually see there's a lot of Banking negative banking and exit so the car wants to slide but there's your apex There's your exit very wide exit, but very off camber It's turn eight Turn eight. No, six. No, that's eight. Eight's down there. No, that's six and eight. Nine over there. Ten, eleven. Well, this is the corner And they change a bit the wall. I mean we can't really see the exit The wall has been moved a bit far on the outside. There's a new There's a lot of cars as well, but there's a new thing on the outside Hello, that's a photographer New tarmac right here. So we go from one on entry to Concrete to tarmac. Last section of the lap if you know Long Beach, you know that part Very grippy here. It's very slippery down there where the drift cars are going So we absolutely don't want to go to one on that exit And then the next one is actually pretty fun and difficult to find the right balance Long Beach, Erpin Come here Get your apex right here And off you go for a very very long straight line So here we are end of day one. It's been a long day I'm for instance with DHR. I'm going to be honest a three hours time difference with Miami a bit painful Going now to Media dinner with the team Actually walking over the paddock. That's the Bit lane right here Straight line down there Yeah, and tomorrow. Finally get to drive Look at that boys. We're kind of quite blurry. So we wait for Carly's day two We're gonna do some social content and guys know we always behind the camera. I know it's in front of it I don't know what to do that guy too. Yes all the questions. Sorry. Sorry, and Carly's late. I don't know what we're gonna do today Hopefully not be able to name Because I'm out of inspiration There you go, guys Look at that. Well, that's what my helmet is. Oh, I need to tell you about this All right, that's a great ball and that's our first win. It's here. He's ready for first win That's my favorite cover all my favorite snacks Can you tell you go for what the big game is See it's on top you're gonna be famous. Yeah, yeah That's why I told him the victory lane If I will you can do anything you want Could I ask you for the will please? For the what? The wheel. Oh, yeah That one could be a bit tighter. That one is a bit longer. Okay. Yeah I'll tighten up that one. On the other side. Is it okay? What is that? All happy. All looks good So just ahead of fruit practice session one we are in my changing room I've got a spare helmet. I've got a race suit and the wear a couple more things in here Got Josh the guy that took some moderators sits here an engineer here And just yeah Let's so far to relax. So that's why I stay proud to race. Say hi to my YouTube. Hey So here we are. Daisy's over and we are a long line of photographs station coming I hope my teammates are too late. That's Kyle coming good That's a social guy. That's for YouTube, brother Morning everyone Saturday 7 a.m. It's an early start here We've got practice 845 945 qualifying 12 to 120 p.m Practice is not gonna be super representative for qualifying because it's freezing cold this morning But we try to give you the best we can and get a good read on the car and get ready for quite It's race day 750 a.m. It's early. It's a bit fresh right now a bit of a cast as well. I've got one of 9 a.m race of 1245 I believe Gonna check a warm of everything is good, but we should have a good car. So Just check the conditions a bit different. Eames our race yesterday for two hours So a bit more rubber on track, but should be good Kirkwood No stranger to leading the junior formulas But this is his first time in the big leagues is Erickson goes to the outside pot of a war trying to make it free wide It's gonna be Kyle Kirkwood leading But side-by-side Grosjean and Joseph Newgarde heading into the found This is one lane only downs and trying to catch up to the back of the field like I was saying earlier Long beach is so unique in that it's the only track we go to where you can't run side-by-side for the last Side as we see one of the McLaren's pot of a war going inside of Grosjean. Oh, it's on Down to tonight here comes Erickson hits in Kirkwood gets away with it Hear the call from the team and Grosjean's in the pits Dave his teammate Grosjean gives up a second place He'll get fresh unused firestone primary tires on there. No changes. Elsewise to the 28 car Out goes that DHL Honda Alexander Ross a young American behind the wheel Kyle Kirkwood is your latest Indy car race winner You have the car today something good to kind One two great here Guys mainly back to Indy P2 in Long Beach pretty exciting Just didn't have enough fuel to use my push to pass and try to get Kyle Kirkwood But all in all a very good weekend a lot of fans Good cars one two four at the finish line fun ready I've got simulator tomorrow, and then we've got Indy 500 open test for the Friday, and then I'll be going home on Saturday Eating my birthday cake with my kids


SCP-775 appears to be a form of arachnid of the order Ixodida, more commonly known as the tick. It is of a significantly larger size, with most unengorged adults reaching a size comparable with a US nickel. Coloration varies between black, red, yellow, gray, and various shades of each. Youths possess eight legs, while juveniles possess only six. SCP-775 is capable of making small leaps, and travels very rapidly along solid surfaces. SCP-775 shares the trait of a flexible body structure, but is much more robust than the common tick, capable of surviving crushing, cutting, or tearing, with little to no damage, and capable of flattening out to slide through 0.25 centimeter gaps.


I found some one-year-old freezer burnt crab legs in my freezer so I'm gonna see if I can save them. Get you three or four feet of some paper towels. Fold them over. Fold them over again. Now we'll get them wet. Unfold it and lay it out flat. Wrap them up. Fold it over. Fold over again. So now they're wrapped up.  Fold it over. Fold it over. Lay out another three feet or so. Roll it. Turn it. Fold it. We're gonna throw it in the microwave. We're gonna take spicy danos and add that to our butter. Uh-oh. It's looking like the meat may have shrunken up a bit. Now I'm gonna give this a try just to see what it tastes like. It does kind of smell a little crabby. It's not horrible. The danos butter will make anything taste good. Don't let your crab sit in the freezer for a year.  We'll see you next time. Keep smirking.


Welcome to Microsoft Project 2013 Part 1. My name is Debbie Fierst, and I'll be your instructor for this course. I've been teaching Microsoft Project since it was first introduced in the early 1990s. I've taught hundreds of students, and I've managed many projects using this tool. Everything from small projects like planning a surgery to long-term projects like closing down an Air Force base. So I'm very familiar with the tool, and I look forward to helping you learn it. In this unit, we're going to define project management. And then we're going to look at how to navigate and customize the Project 2013 interface. We'll learn how to add tasks to a project, how to add resources to a project, and then how to save our project file. In this topic, we're going to learn how to define project management. We'll call it Project Management 101. Let's start with the most basic principle of project management, defining a project. A project is considered a temporary initiative to create a unique result. So some examples of a project would be building a house. It's a temporary initiative. It's going to eventually be completed, and it's unique. Even if we're using some sort of pattern and we're building the same house, again and again, down the same road, each house is still unique. There's going to be unique issues that arise. It's on a different piece of land. And so that's a great example of a project, a temporary initiative, a unique result. Now that we've defined a project, let's define project management. Project management is the administration and supervision of projects using a well-defined set of knowledge, skills, tools, and techniques. Who defines these techniques? Well, in the industry of project management, the Project Management Institute has written a book called The Pimbok, and that's where you'll find the current trends in project management. As far as tools, Microsoft Project is considered one of the most outstanding tools for managing projects. Within the world of project management, we have defined five phases or processes, initiating a project, planning the project, executing, monitoring and controlling, and then closing. Now initiating a project is just getting it started, setting up what we typically call the project charter. Planning is where you set the scope, time, and cost of the project and all the details. That's the tough phase right there, the planning phase. That's where you output your project plan. Then once you've got your plan in place, you're ready to execute. So we go into the executing stage where we actually perform the tasks that we planned. As you're executing, you're also monitoring and controlling what's happening.   Now, in terms of Microsoft Project, that tool is utilized typically most for managing the planning, executing and monitoring and controlling phases. So that's what we'll be focusing on as we learn to use this tool. Since we'll be utilizing Microsoft Project 2013 primarily for the planning, executing, and monitoring and controlling phases, I want to show you that we kind of consider those processes to be iterative, meaning that, as you can see in this diagram, they kind of keep going in a circle as the project goes on. In other words, you don't set a plan for a project and then never plan again as the project unfolds. There's always planning to be done. As a project proceeds, you're going to have new plans that you need to put in place. And as you're executing your tasks in a project, somebody's got to be monitoring and controlling what's happening. So let's take building a house, for example. And let's say we're at the execution stage of putting up our drywall. As someone is hanging the drywall, someone else is monitoring whether that is being done properly and controlling that situation. If we find out that things aren't working the way we had planned, it's possible then that we're going to step back, cycle back to the planning stage and change our plans perhaps for how we're going to do the garage based on how things went with the house on hanging the drywall. Then, when it's time to do the garage, we're back into executing again. Someone is monitoring and controlling that situation and so on. And so you see that this is a great process map showing you how these phases all work together. In addition to our phases that we just discussed, we have knowledge areas inside of the world of project management. And you may find yourself just working in one knowledge area related to a project. Some projects find a project manager who has to work in every area. Others may be so large that there are multiple project managers and they each have their area of expertise. So let's look at some of these knowledge areas. There's one called integration. This is a knowledge area that unifies and coordinates all the many different facets of the project. So an integrative project manager is usually at the top level of managing the project. They're usually going from area to area and making sure everything is working together. They're coordinating. Another knowledge area is scope. This is determining what work is needed to complete a project successfully. So for instance, if I am in charge of doing the drywall inside of building a new house, I'm the expert in that area at determining what is needed and what work is going to be performed to get that drywall done. But I may not know anything about plumbing. I might not know anything about painting. And so someone else might be handling the knowledge area of scope for other areas of the project. Some other knowledge areas are time, cost. Cost is a big one. There are special estimators sometimes on projects who are experts at determining what materials are going to cost, what labor is going to cost. And they only focus on cost. They're accounting types and that's their focus. They could never manage the scope of the drywall. It's just not their area of expertise. We also have quality as a knowledge area. Human resources, right? So there are people who are specializing in getting the right people on the job and assigning them and handling all of the legalities, all of the paperwork to make sure that they're legal and everything is being handled properly and that they're being paid. We have communications. We have risk management. We have procurement. Okay, so these are the primary knowledge areas. So while you might be only knowledgeable about time or cost or quality, it's still helpful to know about the other knowledge areas and have some respect for them. But inside of your project, you may be focusing only on one or two areas. I want to focus on three of the knowledge areas and view them as a triangle. And that is scope, cost, and time. We call these the triple constraint. Because if inside of your project you modify any one of these three things, the other two are going to be impacted. And so I drew a triangle here just to show you. Let's say I have scope here and I have time over here on this side and I have cost down here. And let's take a installation of a refrigerator in a new home that we're building. Okay, we were told that it was going to take one day, oops, that's time, one day, and that it was going to be a certain brand of refrigerator. Okay, so we have a certain brand, a certain type. That's going to be our scope. And the cost was going to be $500, let's say. Okay, so now somebody comes along and they say, I think it's going to take me longer to install the refrigerator. Okay, so they say, no, we estimated a day, but I think it's going to take two days. Well that increases this side of the triangle, right? And there's no way we can increase this side of that triangle without increasing the other two as well, right? Because our installer is going to take double the time, it's going to increase our cost also because we have more labor happening, right? And over here, then scope gets modified as well. So that's why it's called the triple constraint. Because any one of these three things that changes impacts the other two. If somebody says they're going to increase the cost, there's going to be ramifications. Probably the scope is changing. The cost is increasing because they've got more to do. They determined that we forgot some step in the process, something like that. And it's usually going to take more time. Two critical members of the project management team would be the project sponsor and what we call a stakeholder. Typically a project has one sponsor sometimes to or maybe a group is sponsoring the project, but these are people or organizations who authorize, support, and approve the project. So perhaps if we're using the example of building a house, perhaps the bank is building the house, okay? And so it's the bank board who is sponsoring the project. Or perhaps the owner of a homeowner's association is expanding their homeowner area to have an additional home. So maybe a group of homeowners is authorizing the project. Okay, so that would be the sponsor. And they're typically the one that you look to for approval, for support. If you don't keep their support, keep them happy, sometimes the plug gets pulled on the whole project. And then we have stakeholders. Now there's usually more than one stakeholder involved in a project. A stakeholder is anyone who is involved in the project in any way and has some sort of interest in its outcome. There can be internal stakeholders, people who are actually hands-on on the project, right? So the builder is going to be a stakeholder if I'm building a home. The electrician, the plumber, the project manager is a stakeholder, anybody who is involved. And then you can have external stakeholders, people who have an interest in what's going on. Maybe an environmental group is concerned because you're building on a piece of land that's impacting the environment. Or maybe someone inside of the neighborhood doesn't want you building a house there. And so they're actually a stakeholder because they're involved. They have an interest in the outcome of the project. Okay, so we want to pay close attention to our sponsor or sponsors. And all of the stakeholders, a good project manager, has their hand on the pulse of all the stakeholders in trying to keep all those people happy.


Hello, good afternoon. I'm Dave, I'm a software engineer at Red Hat. I'm joined by my colleague Mariam, and yes, we're going to be talking to you about, there we go, migrating from DPTK to XDP for high performance networking in communities with the help of BPF, man, the title was so big it barely fit on the slide. I am a very minor part of the story, so I'm the bit on the end, the of BPF man. Mariam has all of the cool content about the actual AFXDP DPTK migration side, but we're going to run through it in reverse order. I'm going to tell you a little bit about BPF man, what it is, why it exists and how it's helpful in this case, and I'm going to hand over to Mariam to take you the rest of the way. So, BPF man. It was not always called BPF man. It was a project I started about just over two years ago. It was called BPFD when it started. Some of you may have heard me talk about it before. Anybody? Maybe? Yeah, a few people. Fantastic. Good, good. So BPFD, the whole idea behind the project came from me starting to play around with BPF, starting to deploy some programs on just Linux hosts and then furthermore into Kubernetes and realising it was a real pain. There are a lot of annoying things in the BPF API, how some programs behave differently to other ones. Some will stay attached once the program that loaded them exits, some will disappear. And I felt like we could do a better job of abstracting some of that complexity away, and initially I thought, hey, we're going to write a demon. It's going to be like SystemD, but it will be for BPF and it will be amazing. As time passed and some conversations with folks in the community, we realised that a demon might not have been the best choice and we also realised that there are lots of other people loading BPF and we might not always be able to kind of police or look after what they were doing. So in the last six months we've completely rewritten BPF Man from the ground up. The name is a contraction between BPF Manager, BPF Man with a slight fedora hat tip over to Popman who trailblazed the way in the container space. So we've now decomposed BPF Manager to being more of a tool set, some suite of tools that you can use for managing your EBPF in cloud native environments. So we're paving the way for some cloud native EBPF. So what that means in terms of BPF Man and the way that we're doing this is that we have custom resource definitions for BPF programs inside of Kubernetes. All of those CRDs are served by controllers. We have a CSI plug-in that does BPF file system provisioning and everything's packaged up using Kubyamol. You can install it as an operator. You can install it using Customize. There's a whole of a few myriad ways of getting this installed on your cluster to help with your BPF program management needs. Now where some of the cool stuff comes in, at least as far as I think it's cool, in order to make this work in Kubernetes, the first problem we had to solve was how do I take my cool BPF program that I wrote on my machine and get that onto all of the nodes in my cluster. And we figured we already solved that problem for containers, so why not just reuse that entire same pipeline. So we're able to package BPF bytecode into container images, push that through a registry and then BPF Man's able to pull that down, load into the kernel, all of that good stuff for you. The neat thing about that is that all of the tooling for a software supply chain now can equally apply to BPF programs the same way that it does to the rest of the stuff there. We can use tools like Cosign to go and sign our containers, which gives us signatures for the stuff that you're loading into the kernel, which is kind of neat as support for that in BPF land just hasn't quite matured yet. We're able to do kind of signing today. And it allows us to verify with a little bit more work where these programs that come from. So a little piece of work I'm doing on BPF Man at the moment is trying to integrate some more of the policy based verification. So you could say I would like to trust BPF programs that have been published and signed by somebody with a redhat.com email address or an ice availing email address or a data dog email address, but no other programs. So we'll have support for that very, very soon. Finally, I said that BPF Man is now a suite of tools. So aside from loading BPF programs, we're doing some things around the observability of BPF programs as well. So we have two other little tools, one of which does BPF metrics export into hotel. So that will grab some interesting metrics from the BPF subsystem about loaded programs, about maps, about memory usage and explore that in a way that you can use it through your existing observability tools. We also just recently merged a log exporter, which is grabbing logs from audit D. So it will tell you every time a BPF program has been loaded on the system. It will give you some context over who loaded that program. And again, you can ingest that into your telemetry and use that in any way that you see fit. So in terms of how BPF Man works with program loading, we have a very high level declaration of what you want to do, which is your CRD. In this case, it's, hey, BPF Man, please deploy this TC BPF program to the network interface ETH0. And that is the state that gets pushed into Kubernetes. And BPF Man's controller will pick that up and figure out that it's got work to do. The only part of this that runs privileged is BPF Man. So BPF Man is the only thing in this environment that needs the permission to load BPF programs. It's able to fetch your kernel code from an OCI image, pull that down, load that into the kernel, verify the signature. And then in order to make the user space site unprivileged, we use the BPF file system, which is a virtual file system available in Linux. So we're able to go and pin all of your maps onto that so that the user space code without any additional privileges is able to go and read those maps. So if you've got a read-only workflow that you want to use, then you can be completely unprivileged inside of Kubernetes, which is something that we really, really wanted to enable. But this workflow is not for everybody. If you are doing things like compiling programs on demand or your eBPF use case is a little more advanced, it's not going to work because you can't always push your stuff over to a registry. So what we have coming in kernel 6.9 thereabouts is a new patch called BPF tokens, and what that will allow BPF Man to do is here act as a token issuer. So we can keep the same architecture. In this case, you want to deploy a pod that's using BPF programs. BPF Man will then go and provision a file system for you, and it can then go and issue the program with a token to say, hey, you're allowed to make these BPFs this calls. It's all good. You don't need additional privileges to do that.  So that's still work in progress. We're figuring out how exactly to make that work, but that will be landing as soon as we can kind of get our teeth into the kernel patch and figure out how it's going to work. So with that, I will hand you over to Mariam to talk about AFXDP. Okay, so I guess let's start with what is AFXDP. So it's an address family that's optimized for high performance packet processing applications. It promises DPDK-like performance, but with a standard Linux networking interface. It literally attaches a VPF program directly onto the interface, and if we want to be really specific, it's an XDP program that's capable of redirecting packets to an AFXDP socket that sits in users. And then your application consumes things from that AFXDP socket itself. So, you know, you might be wondering, well, you know, is it supported in DPDK? What's the story there? And actually AFXDP has been supported in DPDK since its inception. It's available via the AFXDP PMD. And what I really want to highlight here is that that PMD is actually using your standard Linux I40E driver. It's not using the, if you're familiar with DPDK, it's not using VFIO PCI or IGBUIO. So in essence, it's the actual Linux net dev that's being consumed by this AFXDP PMD. And if you want to use it as part of your DPDK application, you simply need to pass a command line argument, which is the argument we see here on the slide, this minus, minus VDEV argument. What's really cool, or what I think is cool, is that it actually gets consumed as part of the core arguments at every single DPDK application startup. So if you want to transition your DPDK app from using its existing PMD to AFXDP, all you actually need to do is pass this minus, minus VDEV command line argument and boom, it's done. No other application changes should be needed from the DPDK point of view, but obviously if you're deploying with Kubernetes, then you might want to take a few things into consideration and we'll talk about that in a moment. But I guess you might be wondering, you know, why? Why would I want to do this? Out of the box benefits would include observability and portability, and even maybe from a sustainability point of view, if you want to move from a polling model, something that's purely interrupt driven, then this is something that you would leverage. The other thing that you get out of the box is that you can use any standard Linux tool for configuring, managing or observing that network interface. And then, you know, the higher investment benefit is that you can pretty much use a cups or a control and user plane separation type architecture for your application where you essentially split the networking stack where the kernel is your control plane and your DPDK app is your data plane. And you could accomplish this by writing something as simple as a net link agent, for example, that relays routes or other relevant information up into user space for your app.  So if it's control plane traffic, it goes straight to the kernel. If it's data plane traffic, it goes up into user space into your app, and your app only has to worry about processing the traffic that's actually relevant to it, and you avoid this previous model of having to re-inject packets into the kernel from user space. Okay, so provisioning. If you provision a DPDK application or service today, you're probably using the SROV, device plugin and CNI, you could continue to use them. The issue would be that your pod would have to be privileged. Your application pod would have to be privileged to use AFXDP in that context because it would have to load and unload the BPF programs for the networking interfaces. So if we take a moment and we set like two provisioning and deployment goals, the first is that we want to be able to provision, advertise and manage a set of secondary networking interfaces for pods that want to use AFXDP, and that those pods should be able to run without escalated privileges, then you need to use the AFXDP device plugin and CNI. Essentially these two components complement each other to achieve the goals that we list above. So just to walk you through maybe a snapshot of a pod that's created, and this pod is requesting an AFXDP resource, and we're just going to zone in on the net dev allocation time aspect of it. Cublet would invoke the AFXDP device plugin with this allocate device function call. The AFXDP device plugin before BPF man integration was doing this loading of the EBPF program, which is the privilege operation. And then it would pry back to Cublet saying, yeah, add this device to the device spec, but it would also request it to mount a UNIX domain socket into the pod. We'll talk about that in a moment. And then at some stage the AFXDP CNI would get invoked, and this CNI has a number of things that it needs to do, but one of the things that it could do alongside your BPF program, of course, is programming hardware filters on the NIC itself, so packets are delivered to the right cues. And then at some stage your AFXDP pod is up and running, your AFXDP application starts. OK, so now we want to create an AFXDP socket. What do we need? Well, we need a reference to the BPF map that was loaded onto the net dev by the device plugin. That reference is essentially a simple file descriptor, and this is where the UDS comes into place. So the application previously had to connect back to the device plugin over UDS, do this handshake, get this file descriptor, and then create the AFXDP socket, and continue packet processing and doing all this kind of stuff that it was intended to do from the beginning. And this is how we were able to achieve this kind of unprivileged model in that we exported the privileged operations out into the device plugin. And I just wanted to highlight one other thing, I guess, is that in the pod deletion path, the CNI is what's invoked on pod deletion. The device plugin has no awareness of deletion time, and so it had a responsibility of unloading the BPF program. So if we consider those two privileged operations, the loading of the BPF program and the unloading of the BPF program, they actually created quite a number of requirements for the AFXDP device plugin and the CNI. Firstly, we had to store BPF programs in our codebase, which created a lot of churn, especially when not a lot of our engineers wrote the BPF programs. And it also meant that we had a very limited offering of what programs we could offer to folks on the networking interface. Secondly, the CNI runs as a binary on the host right, so you have to statically link all of your dependencies into the CNI, which makes it bulky. You couldn't assume that LibBPF or LibXDP were available on the host, and also had BPF code integrated into the CNI itself. And lastly, we had to do all this loading and unloading of programs pinning of maps, and every time we went to upgrade like our base container image for the device plugin, there would be a different version of LibBPF supported, and we end up having to do some little bits of rewrite here and there, which actually again created quite a bit of churn for us in the project. So, we decided to integrate with BPF man, and what we found were the benefits of that integration essentially was that we were able to remove all of the BPF code from our codebase, and basically significantly reduce the churn for us. It also meant that we no longer need to statically link any dependencies into the CNI, simplifying it, making it smaller, which was another advantage. Through the bytecode OCI image specification that's supported by BPF man, we actually can support a much more diverse set of programs for the pod, you know, it can request anything as long as it has an OCI image somewhere, and BPF man has access to that image. As a next level kind of integration, which is ongoing at the moment, we're also integrating with BPF man to take advantage of their container storage interface driver, which would mean that our BPFFS is actually completely pinned inside the context of the pod, so we don't have to do this, pin something on a host, share it to a pod in a bidirectional fashion for the pod to access it. So, if we review that snapshot again with a couple of updates, so without the CSI plug-in, you know, that alloc function call comes into the AFX3 device plug-in, it uses the BPF man client APIs to request it to load the program, the BPF program on the interface, and then the device plug-in reply back to Kubelet, this time with the device to add a device spec, and before CSI integration it would also give it the pinned, map mount point to mount into the pod, and so eventually when your pod comes up, you might notice like there's no handshake anymore, your pod can simply do BPF object get and it can start running and executing straight away, and I think getting rid of the handshake to be honest with you is a benefit for us because it placed a requirement on the application that I don't think it actually needed now that we can use BPF object get. And so, with the container storage interface integration side, just like one other addition into the picture, so let's start at the alloc call coming into the device plug-in, BPF man loads the program on the interface, and the device plug-in now is just going to set a few annotations on the pod, which are the XDP program name, the map name, and where to pin them inside the context of the pod. Kubelet will ask BPF man to actually mount that volume inside the pod context, and when the pod is up and running it has a completely cordoned off BPFFS with the map that it needs to itself, does BPF object get and off it goes. So, you know, theory is obviously much more strong if it's supported by evidence, and what we did was we actually took the OpenMobile Evolved Core, which is an open source 5G core data plane, it had this UPF implementation specifically that was based on DPDK and SROV. We migrated it to AFXDP using that minus-minus VDEV argument that we saw earlier on in the slides without making any changes to the app, and we actually have a demo recorded, but I won't show it today, I will leave people to watch that in their own time. It's showing basically an unprivileged OMEC UPF pod coming up and it's being deployed by AFXDP device plug-in, CNI, and BPF man. In summary, you know, we found that there was a real development and maintenance cost to independently trying to manage BPF inside our own infrastructure entity, and essentially, you know, I think the device plug-in and the CNI are a real use case that show the benefit of leveraging a centralized manager in Kubernetes. Thank you. Thank you for that talk. Now we have time for a couple of questions, if there are any. Did you agree on an interface between BPF man and AFXDP device plug-in to make sure that, for example, BPF man never breaks AFXDP device plug-ins? I don't think we had to make any agreement to be honest with you. BPF man works in a pretty standard way and how it loads programs on the interface. So the change was actually, I'm going to be really honest, really simple. So I just replaced all the code in the AFXDP device plug-in that was previously loading, unloading BPF programs and so on with a BPF client API call. It was that simple. Hi, great talk. My experience with DPDK was usually to run it in a VM, so my question would be, do you have experience with QMU and AFXDP, or do you know if that works well? I've seen patches fly through on the mailing list quite recently to integrate it, so I imagine, you know, native support would be coming relatively soon in that environment, yeah. One question about the slide where you are running unprivileged BPF programs. Do you happen to use it, right as a non-root user, or does it need to be a root user to run that? So I was taking a very simple DPDK app, which was already running as a root user, but I think it should work in a non-root user context. I haven't tried it. I was trying to work on the premise that I was using DPDK as it would be deployed today. Right, okay, that's good to know because I tried this. We couldn't get it to work. This was like several months ago, so things might have changed. The other question to this was, did you have to enable that unprivileged BPF flag in the kernel? No, but not for the integration mark that happened, no, but in previous work when we were using the device plugin natively we did, yes. Right, and what kernel version were you using for this? For this demo that we did or just in general, I think I used... Were you quite working? Yes, so it was an Ubuntu image, and I think it was using a 5-dash... More than 5.19 it was like 5-dash something kernel, but it was above 5.19, yes. Okay, that's fairly old. Thank you. Yes, the image for the Omec UPF was quite old, so I didn't have much of an option unfortunately. It was LTS, Ubuntu and kernel. Okay, thanks for the talk. We're now going to... ...


Well, hello, I'm Deadpool. The nice guys from drinks made easy made a special Valentine's Day cocktail in honor of me my movie and my Best girl It's called the best girl cocktail Be sure to check out my movie To build the Deadpool best girl cocktail. You'll start by adding three thin slices of cucumber Next you'll add seven raspberries or roughly a small handful and then a handful of mint Now get your handful And what you're gonna do is you're gonna give it a quick compression What this is gonna do is help the oils come out to the surface and get more of that mint flavor into your cocktail Next we're gonna muddle this and while I'm muddling you can take a quick look at this awesome dead pool clip When you find out your worst enemy is after your best girl the time has come to be fucking superhero Next you'll add an ounce and a half of beefy to Jim Three quarters of an ounce of Benedictine Half an ounce of runny honey, which is three parts honey to one part water half an ounce of fresh lime juice half an ounce of fresh grapefruit juice Then you're gonna cap that off into a shaker tin full of ice and give it a good shake You don't want to double strain this cocktail because there's a lot of little bits of seed and pulp From both the mint and the fresh raspberries Top that off with some soda water Give it a little stir, and then we're gonna garnish it with a fresh mint sprig put through one of our cucumber wheels and couple of raspberries and There you have the dead pool best girl cocktail pretty cool, huh? Be sure to like comment and subscribe below There's also an Easter egg if you click around and find it and comment below They promise to make the brown pants cocktail. This guy's got the right idea Thanks so much for watching and please remember to always drink responsibly because everybody likes to make friends But no one likes to make them in a prison shower. We're gonna need to do another one of that. That was perfect. No, it wasn't